void mButtonCreateContact_Click(object sender, EventArgs e) { if (OnCreateContact != null) { //Broadcast event OnCreateContact.Invoke(this, new CreateContactEventArgs(txtName.Text, txtNumber.Text)); } this.Dismiss(); }
void mButtonCreateContact_Click(object sender, EventArgs e) { if (OnCreateContact != null) { //Broadcast event OnCreateContact.Invoke(this, new CreateContactEventArgs(txtName.Text, txtDatePicker.DateTime.ToLongDateString())); } this.Dismiss(); }
void client_UploadValuesCompleted(object sender, UploadValuesCompletedEventArgs e) { Activity.RunOnUiThread(() => { string id = Encoding.UTF8.GetString(e.Result); //Get the data echo backed from PHP int newID = 0; int.TryParse(id, out newID); //Cast the id to an integer if (OnCreateContact != null) { //Broadcast event OnCreateContact.Invoke(this, new CreateContactEventArgs(newID, txtName.Text, txtNumber.Text)); } mProgressBar.Visibility = ViewStates.Invisible; this.Dismiss(); }); }