Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Howto: Run PDA application after OS starts?

8 views
Skip to first unread message

Topper

unread,
Jan 18, 2005, 3:25:54 AM1/18/05
to
Hello all.

How can i run my PDA application automatically after OS starts?

Thank you.


Sergey Bogdanov

unread,
Jan 18, 2005, 3:40:03 AM1/18/05
to
There are several ways for it:

1. Create shortcut to your application in \Windows\Startup:

SHCreateShortcut(@"\Windows\StartUp\" +
Path.GetFileNameWithoutExtension(applicationPath) + ".lnk", "\"" +
applicationPath + "\"");

...

[DllImport("coredll.dll", EntryPoint="SHCreateShortcut") ]
private static extern bool SHCreateShortcut(string shortcut, string target);


2. Add key to HKLM\Init:
http://www.opennetcf.org/SourceBrowse/view.aspx?f=d:/sites/OpenNETCF/InetPub/wwwroot/Source/OpenNETCF/Win32/Registry.cs

3. Use P/Invoke CeRunAppAtEvent (Wakeup = 0x0B)

Best regards,
Sergey Bogdanov
http://www.sergeybogdanov.com

0 new messages