Just a simple question

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

how can I open the Date and Time Property Window from my App?

I guess that should be a simple process but I can't find information about
it...

Best Regards
 
ProcessStartInfo pi = new ProcessStartInfo("control", "timedate.cpl");
System.Diagnostics.Process.Start(pi);

"Diogo Alves - Software Developer"
 
"Diogo Alves - Software Developer"
how can I open the Date and Time Property Window from my App?

I don't know if this is the "right" way, but if you add a COM reference to
<windows>\System32\Shell32.dll to your project then the code:
using Shell32;
...
ShellClass shell = new ShellClass();
shell.SetTime();
seems to work.

Chris Jobson
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top