private void Btn_create_Click(object sender, EventArgs e) { string name = Txt_nam_create.Text; string surname = Txt_sur_create.Text; if (Txt_phone_create.Text.Length > 8 && Txt_phone_create.Text.Length < 13) { string phone = Txt_phone_create.Text; api.insertWorker(name, surname, phone); Display(); } else { MessageBox.Show("Vnesi veljavno telefonsko številko"); } }