title: Why Control.FromHandle(IntPtr) returns null in one hooked process and returns valid object of "Form"? in another hooked process?
body: <p>I am facing a problem related to get out all the controls from some hooked process. My SpyDll launched into hooked process sucessfully, But when I check the statement </p>
  
  <p>Control control = Control.FromHandle(MainWindowHandle), it returns null into control object  where "MainWindowhandle"is just a native main window handle of that hooked process, which you always take from .NET "Process" class after launching that process.</p>
  
  <p>But STRANGLY it happens that in some other hooked process which is the same C# .NET application, it returns valid object of Main "WinForm".</p>
  
  <p>So why it will not work in above case? Are there any exceptions to use "MainWindowHandle" properly. In my case both are seperate .NET managed processes programmed in C#. Any process configuration needs to maintain specially while creating that process?</p>
  
  <p>Regards
  Usman</p>