private Boolean CheckApplicationDetails() { if (AppDetailIsEmpty()) { MessageBox.Show("Please Enter Proper details"); return(false); } int appid = 1; try { appid = Convert.ToInt32(txtAppID.Text); } catch { MessageBox.Show("ApplicationID must be a valid number"); return(false); } if (Accessor.ApplicationID_Exists(appid)) { MessageBox.Show("ApplicationID Already Exists"); return(false); } return(true); }