954,577 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

System.ComponentModel.Win32Exception: The handle is invalid

Hi

I am using an instance of System.Drawing.Graphics class in my application
System.Drawing.Graphics gfxScreenshot;

I have used copyfromscreen method of this class.

gfxScreenshot.CopyFromScreen(System.Windows.Forms.Screen.PrimaryScreen.Bounds.X, System.Windows.Forms.Screen.PrimaryScreen.Bounds.Y, 0, 0, System.Windows.Forms.Screen.PrimaryScreen.Bounds.Size, System.Drawing.CopyPixelOperation.SourceCopy);

Its working fine locally but on remote machine its firing the error saying
System.ComponentModel.Win32Exception: The handle is invalid
Iam unable to trace out the error. Please help me if anyone know this. I have been crashing my head for 2 weeks.
Thanking you in advance
Regards
Anil

AnilReddy
Newbie Poster
10 posts since Jan 2009
Reputation Points: 10
Solved Threads: 0
 
neel05
Newbie Poster
1 post since Mar 2009
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You