private async void BtnAdd_Clicked(object sender, EventArgs e) { byte[] imageArray = null; if (this.file != null) { imageArray = FilesHelper.ReadFully(this.file.GetStream()); } Student student = new Student { Name = EntryName.Text, Age = Convert.ToInt32(EntryAge.Text), Mobile = EntryMobile.Text, StageSchool = StageSchool, ImageArray = imageArray }; await ApiService.AddStudent(student); await DisplayAlert("الاضافه", "تمت", "نعم"); }