void RegisterButton_Clicked(object sender, EventArgs e) { datalist contact = new datalist() { Username = username.Text, FirstName = firstname.Text, LastName = lastname.Text, EmailId = emailid.Text, Password = password.Text }; if (username == null && firstname == null && lastname == null && emailid == null && password == null) { DisplayAlert("Alert", "Please enter valid details", "Ok"); } else { using (SQLite.SQLiteConnection conn = new SQLiteConnection(App.FilePath)) { conn.CreateTable <datalist>(); int rowsAdded = conn.Insert(contact); DisplayAlert("Alert", "Registered Successfully", "Ok"); } } }
public listsController(datalist context) { _context = context; }