示例#1
0
        private void btn_GetBrotherWindowTree_Click(object sender, EventArgs e)
        {
            AccessWin aw = new AccessWin();

            AccessWin.WindowsTree wt = new AccessWin.WindowsTree();
            IntPtr pt = new IntPtr(Convert.ToInt32(txt_SelectedCell.Text, 16));

            txt_handle.Text = pt.ToString("X");  //display the handle in textbox
            //IntPtr vHandle = new IntPtr(Convert.ToInt32(txt_ListHandle.Text, 16));

            dgv_child.DataSource = aw.ListBrotherWindow(pt).toDatatable();
        }
示例#2
0
        private void btn_FilterHWND_Click(object sender, EventArgs e)
        {
            AccessWin aw = new AccessWin();

            AccessWin.WindowsTree wt = new AccessWin.WindowsTree();
            IntPtr pt = aw.GetWindowHandlebyTitle(txt_APPTitle.Text);

            txt_handle.Text = pt.ToString("X");  //display the handle in textbox
            //IntPtr vHandle = new IntPtr(Convert.ToInt32(txt_ListHandle.Text, 16));
            wt = aw.ListWindow(pt);
            try
            {
                dgv_list.DataSource = wt.FiltedbyHWND(Convert.ToInt32(txt_FilterHWND.Text, 16)).toDatatable();
            }
            catch
            { }
        }
示例#3
0
        private void btn_GetWindowList_Click(object sender, EventArgs e)
        {
            AccessWin aw = new AccessWin();

            AccessWin.WindowsTree wt = new AccessWin.WindowsTree();

            IntPtr pt = aw.GetWindowHandlebyTitle(txt_APPTitle.Text);

            txt_handle.Text = pt.ToString("X");  //display the handle in textbox
            //IntPtr vHandle = new IntPtr(Convert.ToInt32(txt_hndle.Text, 16));
            if (aw != null)
            {
                DataTable dt = new DataTable();
                dt = aw.ListWindow(pt).toDatatable();
                //dgv_list.DataSource = dt;
                AccessWin.WindowsTree wt2 = new AccessWin.WindowsTree();
                wt2.GetfromDataTable(dt);
                DataTable dt2 = wt2.toDatatable();
                dgv_list.DataSource = dt2;
            }
        }