private void AddInstagramAccount_Click(object sender, EventArgs e) { var instagramAccount = new InstagramAccount() { EmailPhone = instaEmailPhone.Text, Password = instaPassword.Text, UserId = SQLiteDatabaseAccess.GetLoggedUser().Id, FollowedPersonLinkString = Guid.NewGuid().ToString(), LikedPersonLinkString = Guid.NewGuid().ToString(), }; try { var succes = SQLiteDatabaseAccess.AddInstagramAccount(instagramAccount); if (succes) { MessageBox.Show("Added account with success", "Success", MessageBoxButtons.OK, MessageBoxIcon.Exclamation, MessageBoxDefaultButton.Button1); // clear listview and display new list listOfInstagramAccounts.Clear(); LoadInstaAccountsFromDB(); } else { MessageBox.Show("Problems occured adding the account", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation, MessageBoxDefaultButton.Button1); instaEmailPhone.Clear(); instaPassword.Clear(); } } catch (Exception ex) { } }