Ralax
unread,Jun 7, 2009, 2:20:15 AM6/7/09Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to DotNetDevelopment, VB.NET, C# .NET, ADO.NET, ASP.NET, XML, XML Web Services,.NET Remoting
Try the following code:
namespace ProcessHandle
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Get the process handle example.");
var process = new Process
{
StartInfo = new ProcessStartInfo
("explorer.exe", @"c:\")
};
process.Start();
Console.WriteLine("Process Id: " + process.Id);
Console.WriteLine("Process Name: " + process.ProcessName);
Console.WriteLine("Process Handle(IntPtr): " +
process.Handle.ToString());
Console.ReadLine();
}
}
}
use the above code, you can get the handle of the new opened window,
and then use win api set the position.