private void load_UCListSanPham() { this.Tag = maBK; if (hinhAnhBanhKem == string.Empty) { hinhAnhBanhKem = "product.png"; } var imageMS = new MemoryStream(webservice.get_imageFile(hinhAnhBanhKem)); Image imageFS = Image.FromStream(imageMS); anhsp.Image = imageFS; lb_TenBanhKem.Text = this.tenBanhKem; lb_Loai.Text = this.tenLoai; this.MouseClick += Control_MouseClick; foreach (Control control in Controls) { control.MouseClick += Control_MouseClick; } }
private void TTBK_Load(object sender, EventArgs e) { this.Tag = maBanh; if (hinhAnhBK == string.Empty) { hinhAnhBK = "product.png"; } var imageMS = new MemoryStream(webservice.get_imageFile(hinhAnhBK)); Image imageFS = Image.FromStream(imageMS); anhsp.Image = imageFS; lb_TenBanhKemVaSize.Text = this.tenBK; lb_TenSize.Text = this.tenSize; lb_LoaiBanhKem.Text = this.ngaySX.ToShortDateString(); lbmaBTN.Text = this.maBanh.ToString(); this.MouseClick += Control_MouseClick; foreach (Control control in Controls) { control.MouseClick += Control_MouseClick; } }