This website is using cookies. We use cookies to ensure that we give you the best experience on our website. More info. That's Fine
HPC:Factor Logo 

How to run a .bat file on a Windows CE Handheld PC using cmd.exe


Applies To

  • Windows CE 2.11, 3.0, 4.0, 4.1, 4.2, 5.0, 6.0
  • Handheld PC Professional, HPC2000


This article outlines how you can register the .bat and .cmd file type extensions on your Windows CE device to allow for the manual or automatic (startup script) execution of a Batch (bat) or Command Script file (cmd).

More Info

By default, the Windows CE environment does not expose registrations for the bat file and cmd file types. In order to use these script types you will have to manually register the file extensions.

How-to Guide

You will require access to a registry editor in order to complete this article. If you require more information on using the Windows CE Registry see CESDS0006. If you require a Windows CE Registry Editor see CESDS0082.

WARNING: If you use a Registry Editor incorrectly, you may cause serious problems that may require you to hard reset your Handheld PC back to its factory installed configuration. Edit your Windows CE registry at your own risk.






@=""\\Windows\\cmd.exe /c %1""

Once you have entered the information correctly into the registry, soft reset your Handheld PC for the changes to take effect.