0
Reply

The handle is invalid

Nasurudeen Yasu

Nasurudeen Yasu

Nov 15 2012 1:46 AM
1.6k
i am try to capture the scree by using following coding..

Dim gr As Graphics
        bm =
New Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height, Drawing.Imaging.PixelFormat.Format32bppArgb)
        gr = Graphics.FromImage(bm)
        gr.CopyFromScreen(Screen.PrimaryScreen.Bounds.X, Screen.PrimaryScreen.Bounds.Y, 0, 0,
New Size(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height))but


"The handle is invalid" error occoured..