private void btnOpenFile_Click(object sender, EventArgs e)
        {
            OpenFileDialog fileDialog = new OpenFileDialog();

            fileDialog.Title            = "Select video file";
            fileDialog.Filter           = "h264 files (*.h264)|*.h264";
            fileDialog.FilterIndex      = 1;
            fileDialog.RestoreDirectory = true;

            if (fileDialog.ShowDialog() == DialogResult.OK)
            {
                String fileName = fileDialog.FileName;
                m_nLocalplayHandle = Convert.ToInt32(XMSDK.H264_DVR_StartLocalPlay(fileName, pictureBoxVideoWnd.Handle, null, Convert.ToUInt32(0)));
                if (m_nLocalplayHandle > 0)
                {
                    timerLocalPlayBack.Elapsed  += new System.Timers.ElapsedEventHandler(recordTime);
                    timerLocalPlayBack.AutoReset = true;
                    timerLocalPlayBack.Enabled   = true;
                    XMSDK.fLocalPlayFileCallBack fileEndCallBack = new XMSDK.fLocalPlayFileCallBack(FileEndCallBack);
                    XMSDK.H264_DVR_SetFileEndCallBack(m_nLocalplayHandle, fileEndCallBack, this.Handle);
                }
                else
                {
                    MessageBox.Show("failed");
                }
            }
            else
            {
            }
        }