コード例 #1
0
 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);
     }
 }
コード例 #2
0
 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);
     }
 }
コード例 #3
0
 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);
     }
 }