public override void ViewDidLoad() { base.ViewDidLoad(); RegButton.TouchUpInside += (object sender, EventArgs e) => { Name = NameText.Text; Age = AgeText.Text; Mail = MailText.Text; SetregistrationInformation(Name, Age, Mail); UserClient.Connect("10.0.1.5", GetregistrationInformation()); }; }