Running a bat file at windows CE boot



Hi All:

I want to start a bat file at windows ce startup. I tried to modify
"HKEY_LOCAL_MACHINE\init" in the registry but did not work out. I suspect it
only accepts exe's. Then I have tried to make small exe application and
launch a bat file, but have not succeeded there either. My sourcode looks
like:

PROCESS_INFORMATION pi;
ZeroMemory(&pi, sizeof(pi));
if (CreateProcess(TEXT("\\windows\\cmd.exe"),TEXT("/C
\\windows\\IBMjvm.bat"), NULL, NULL, FALSE,CREATE_NEW_CONSOLE, NULL, NULL,
NULL, &pi))
{
CloseHandle(pi.hThread);
CloseHandle(pi.hProcess);
}
WaitForSingleObject(pi.hProcess, INFINITE);
Sleep(1000);
return 0;

This small exe application can launch IBMjvm.bat if I run it under telnet
console instead of runing at the boot time.

Please help,

Chuck dot Lin at Symbol dot Com


.



Relevant Pages

  • Re: self replacing EXE
    ... "David" wrote in message ... >>> regards to an EXE that could delete and replace itself. ... >>> know I can simply use a script or bat file to copy the newer compiled ... >> replace them if required and then launch another app with a command line ...
    (microsoft.public.vb.general.discussion)
  • Re: running batch file at Windows CE 5.0 boot time
    ... needed, newsreader software handles it like a single message, so you can ... I want to start a bat file at windows ce startup. ... and launch a bat file, but have not succeeded there either. ... Chuck dot Lin @ Symbol dot COM ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: running batch file at Windows CE 5.0 boot time
    ... I want to start a bat file at windows ce startup. ... launch a bat file, but have not succeeded there either. ... Any work around to launch batch file in the boot time. ... Chuck dot Lin @ Symbol dot COM ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: Running a bat file at windows CE 5.0 boot
    ... I want to start a bat file at windows ce startup. ... launch a bat file, but have not succeeded there either. ... Any work around to launch batch file in the boot time. ... Chuck dot Lin @ Symbol dot COM ...
    (microsoft.public.windowsce.app.development)
  • running batch file at Windows CE 5.0 boot time
    ... I want to start a bat file at windows ce startup. ... launch a bat file, but have not succeeded there either. ... Any work around to launch batch file in the boot time. ... Chuck dot Lin @ Symbol dot COM ...
    (microsoft.public.windowsce.embedded.vc)