There are three common ways to run an app at startup on a Windows CE device
(2.0 or newer
):
1
) create a link to the app in the \Windows\Startup folder
(the most common method
);
2
) create a string value called LaunchXX that points to the file in HKEY_LOCAL_MACHINE/init in the registry, where XX represents a two-digit decimal number higher than the LaunchXX value for explorer.exe
(this also requires creating a DWORD value called DependXX for this app pointing to a file it requires to be executed first among those with lower LaunchXX numbers already present in the HKLM/init key
)
(this method can be used for PNAs and other devices with newer versions of CE that have persistent registries but whose \Windows folders are located in non-persistent RAM
); or
3
) rename the executable
autorun.exe and place it in on a Storage Card in a folder whose name is a numeric value identifying its processor type
(on ARM-based devices, this is generally \Storage Card\2577\
)
(this method can also be used for automatically executing a program on the Storage Card once the card is inserted in an already-booted device
).
After obtaining a second Mintpass MintPad, I've been forced to try method 3
) after installing .NET CF 3.5 on my first one, which bricked that MintPad.
(It turns out that the MintPad's proprietary interface, into which it boots directly [the file being called Launcher.exe], is a .NET CF 2.0 app, and because the MintPad doesn't retain registry changes after reboot, the necessary registry entries to allow backward compatibility of .NET CF 3.5 are missing during reboot. So the device just hangs at the startup splash screen.
) But this method isn't working thus far. I've seen some stuff on the Web suggesting that not every CE device is set up by its OEM to enable the ability to autorun files this way. Can someone confirm this? Also, is it possible to tell the device to look somewhere other than \Storage Card for the folder where the autorun file resides, such as through an autorun.inf file
(which I've seen in the file systems of some devices
)? Because the device will no longer connect via ActiveSync, only the NAND storage area and the Storage Card
(when a TF/microSD card is inserted in the interior slot behind the battery
) are accessible when the device is connected to a PC, and only then when an "Emergency" mode is enabled by a series of button and switch combinations. So far I haven't been able to find a way to unbrick this device through this route, and the Mintpass site is now closed and its page contents not fully archived in the Wayback Machine.