| View previous topic :: View next topic |
| Author |
Message |
DanTheMan Contributor


Joined: 15 Mar 2002 Posts: 56 Location: Sweden
|
Posted: Wed Jan 29, 2003 1:40 pm Post subject: Activate a DOS (full Screen) program from VDS |
|
|
VDS window commands seems to have a problem activating
A DOS (full screen) program from the windows task bar.
It works fine when running from the VDS development environment (IDE),
but not from a compiled script (exe). Propeties for the Dos-promt Shortcut is set to Fullscreen. (everything works fine if set to window). Windows XP and VDS 4.51, Anyone ?
Example:
title DOS TEST
%W = dos-prompt
if @not(@WinExists(%W))
directory change,c:\test
shell "", C:\Documents and Settings\dga\Start-meny\Program\dos prompt.lnk
else
Window activate,%W
Window ontop,%W
end
exit |
|
| Back to top |
|
 |
Skit3000 Admin Team

Joined: 11 May 2002 Posts: 2166 Location: The Netherlands
|
Posted: Wed Jan 29, 2003 2:48 pm Post subject: |
|
|
Maybe you should use the window maximize command. I don't know if it makes a window full screen, but you can give it a try...
BTW. Maybe you should work with the Classname of the console window, #ConsoleWindowClass (Windows XP) |
|
| Back to top |
|
 |
MarkTrubo Contributor


Joined: 27 May 2001 Posts: 148 Location: Long Island, NY
|
Posted: Wed Jan 29, 2003 2:58 pm Post subject: |
|
|
On XP, I use:
RUN command.com
:ISITOPEN
IF @WINEXISTS(#ConsoleWindowClass)
GOTO SOMETHING
END
WAIT 1
GOTO ISITOPEN
:SOMETHING
You could use RUNM to maximize it. |
|
| Back to top |
|
 |
FreezingFire Admin Team

Joined: 23 Jun 2002 Posts: 3508
|
Posted: Wed Jan 29, 2003 10:27 pm Post subject: |
|
|
To activate the window you could try the following:
| Code: | rem The following two lines are used for example only
runz cmd.exe
warn Click OK when #ConsoleWindowClass is not active...
rem ----------------------------------------------------------------
if @winexists(#ConsoleWindowClass)
window send,#ConsoleWindowClass," "
else
warn #ConsoleWindowClass does not exist!
end |
_________________ FreezingFire
VDSWORLD.com
Site Admin Team |
|
| Back to top |
|
 |
DanTheMan Contributor


Joined: 15 Mar 2002 Posts: 56 Location: Sweden
|
Posted: Thu Jan 30, 2003 8:57 am Post subject: |
|
|
Thank's for your answers but the problem still exists ....
FreezingFire!, I'll tryed your example and it works ok if the Dos program
runs in a window but not if it runs in full Screen mode. I'll think VDS
cannot send keystrokes to Dos programs running in full screen mode ? |
|
| Back to top |
|
 |
MarkTrubo Contributor


Joined: 27 May 2001 Posts: 148 Location: Long Island, NY
|
Posted: Thu Jan 30, 2003 11:30 am Post subject: |
|
|
| I just did a simple test with a dos window in full screen mode on XP Home and VDS did send the keys to the window. |
|
| Back to top |
|
 |
DanTheMan Contributor


Joined: 15 Mar 2002 Posts: 56 Location: Sweden
|
Posted: Thu Jan 30, 2003 1:54 pm Post subject: |
|
|
@MarkTrubo
Hmmm.. Strange !, I'm running a XP-pro, but anyway ...
Could you please do this ?, ( just to be sure we do the same ...)
Compile this prog example from "FreezingFire" and make a Shortcut to it from your desktop.
title dos_test
if @winexists(#ConsoleWindowClass)
window send,#ConsoleWindowClass," "
else
warn #ConsoleWindowClass does not exist!
end
exit
Then:
enter: CMD (on start > run)
press: alt+enter (to force Full screen mode)
change back to Desktop (cmd shell now minimized on taskbar)
Run prog. from the Shortcut.
For me it still remains on taskbar. (for window propeties it works just fine)
Thanks in advance!
Dan |
|
| Back to top |
|
 |
|