+#ifndef STANDALONE
+
+ while (TRUE)
+ {
+ /* Clear the structure */
+ ZeroMemory(&CommandInfo, sizeof(CommandInfo));
+
+ /* Initialize the structure members */
+ CommandInfo.VDMState = VDM_NOT_LOADED;
+ CommandInfo.CmdLine = CmdLine;
+ CommandInfo.CmdLen = sizeof(CmdLine);
+ CommandInfo.AppName = AppName;
+ CommandInfo.AppLen = sizeof(AppName);
+ CommandInfo.PifFile = PifFile;
+ CommandInfo.PifLen = sizeof(PifFile);
+ CommandInfo.Desktop = Desktop;
+ CommandInfo.DesktopLen = sizeof(Desktop);
+ CommandInfo.Title = Title;
+ CommandInfo.TitleLen = sizeof(Title);
+
+ if (!GetNextVDMCommand(&CommandInfo)) break;
+
+ /* Start the process from the command line */
+ if (!DosCreateProcess(AppName, 0))
+ {
+ DisplayMessage(L"Could not start program: %S", AppName);
+ goto Cleanup;
+ }
+
+ /* Start simulation */
+ EmulatorSimulate();
+
+ /* Perform another screen refresh */
+ VgaRefreshDisplay();
+ }
+
+#else
+