Exemplo n.º 1
0
        private void FillGrig()
        {
            HPS.BLL.InOutPicturesBLL.BLLInOutPictures_TFactory InOutPicturesFactory = new BLL.InOutPicturesBLL.BLLInOutPictures_TFactory();
            List <HPS.BLL.InOutPicturesBLL.BLLInOutPictures_T> InOutPicturesList    = new List <BLL.InOutPicturesBLL.BLLInOutPictures_T>();

            InOutPicturesList = InOutPicturesFactory.GetAllBy(BLL.InOutPicturesBLL.BLLInOutPictures_T.InOutPictures_TField.inOutID_bint, TrafficPicturesGridView.CurrentRow.Cells[colinOutID_bint.Name].Value);

            if (InOutPicturesList != null && InOutPicturesList.Count > 0)
            {
                if (InOutPicturesList[0].picture_vbnry != null)
                {
                    System.IO.MemoryStream pictureMemoryStream = new System.IO.MemoryStream();
                    pictureMemoryStream.Write(InOutPicturesList[0].picture_vbnry, 0, InOutPicturesList[0].picture_vbnry.Length);
                    pictureBox.Image = System.Drawing.Image.FromStream(pictureMemoryStream);
                }
            }
        }
Exemplo n.º 2
0
        private void AcceptedTurnGridView_RowDoubleClick(object sender, Janus.Windows.GridEX.RowActionEventArgs e)
        {
            try
            {
                HPS.BLL.InOutPicturesBLL.BLLInOutPictures_TFactory InOutPicturesFactory = new BLL.InOutPicturesBLL.BLLInOutPictures_TFactory();
                List <HPS.BLL.InOutPicturesBLL.BLLInOutPictures_T> InOutPicturesList    = new List <BLL.InOutPicturesBLL.BLLInOutPictures_T>();
                InOutPicturesList = InOutPicturesFactory.GetAllBy(BLL.InOutPicturesBLL.BLLInOutPictures_T.InOutPictures_TField.inOutID_bint, InOutTimesGrid.CurrentRow.Cells["inOutID_bint"].Value);

                if (InOutPicturesList != null && InOutPicturesList.Count > 0)
                {
                    if (InOutPicturesList[0].picture_vbnry != null)
                    {
                        System.IO.MemoryStream pictureMemoryStream = new System.IO.MemoryStream();
                        pictureMemoryStream.Write(InOutPicturesList[0].picture_vbnry, 0, InOutPicturesList[0].picture_vbnry.Length);
                        pictureBox.Image = System.Drawing.Image.FromStream(pictureMemoryStream);
                    }
                }
            }
            catch (Exception ex)
            {
                Hepsa.Core.Common.MessageBox.ErrorMessage(ex.Message);
            }
        }