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

Windows CE 5.0, USB memory stick, autorun batch file

850 views
Skip to first unread message

Juusos

unread,
Nov 30, 2009, 4:38:07 AM11/30/09
to
hi,

how can i automatically start a batch file (e.g. autorun.bat) from an
usb stick when it is inserted into Windows CE 5.0 machine?

Regards,

Marko

Bill T

unread,
Nov 30, 2009, 9:17:01 AM11/30/09
to

Bruce Eitman [eMVP]

unread,
Nov 30, 2009, 10:51:54 AM11/30/09
to
The code in that article looks for exe files to run, but it wouldn't take
much to change it to look for bat files, or a specific bat file. You will
also need to change the call to CreateProcess() to run cmd.exe and pass in
the bat file as an argument. You might need to make the arguement either
"/c myfile.bat" or "/k myfile.bat"

--
Bruce Eitman (eMVP)
Senior Engineer
Bruce.Eitman AT Eurotech DOT com
My BLOG http://geekswithblogs.net/bruceeitman

Eurotech Inc.
www.Eurotech.com

"Bill T" <Bi...@discussions.microsoft.com> wrote in message
news:74372632-0553-4644...@microsoft.com...

0 new messages