private void btnChoosePhoto_Click_1(object sender, EventArgs e) { //open the Open File Dialog.If user clicks OK, load the picture that user chose. if (PhotoOpenFileDialog.ShowDialog() == DialogResult.OK) { PhotoPictureBox.Load(PhotoOpenFileDialog.FileName); } }
public TitledPictureControl(IDescriptivePicture i_DescriptivePicture, string i_Id) { InitializeComponent(); WireAllControls(this); m_Id = i_Id; TitleLabel.Text = i_DescriptivePicture.Description; if (!string.IsNullOrEmpty(i_DescriptivePicture.PictureUrl)) { PhotoPictureBox.LoadAsync(i_DescriptivePicture.PictureUrl); } }
public TitledPictureControl(string i_ImageUrl, string i_Title, string i_Id) { InitializeComponent(); WireAllControls(this); m_Id = i_Id; TitleLabel.Text = i_Title; if (!string.IsNullOrEmpty(i_ImageUrl)) { PhotoPictureBox.LoadAsync(i_ImageUrl); } }