| View previous topic :: View next topic |
| Author |
Message |
vtol Valued Contributor


Joined: 05 Feb 2004 Posts: 656 Location: Eastern Indiana
|
Posted: Mon Sep 24, 2007 4:36 am Post subject: A way to get Win system32 PATH with DOS batch or other way. |
|
|
Hi
I would like to find a way to get the Windows XP system32 PATH with a DOS batch file or small C EXE that excepts parameters from my VDS5 EXE.
(1) It would get the Windows\system32 path.
(2) Maybe write it to a txt file or registry or %1 etc.. |
|
| Back to top |
|
 |
ShinobiSoft Professional Member


Joined: 06 Nov 2002 Posts: 790 Location: Knoxville, Tn
|
Posted: Mon Sep 24, 2007 4:54 am Post subject: |
|
|
Hi Vtol,
I can think of two ways off the top of my head to get the system path.
Bothe are APIs by the way::
1) UINT GetSystemDirectory(LPTSTR lpBuf, UINT uSize);
2) BOOL SHGetSpecialFolderPath(HWND hwndOwner, LPTSTR lpBuf, int iFolder, BOOL fCreate);
For #2 set 'iFolder' to CSIDL_SYSTEM. Not sure what the actual value is.
As for the reaminder of your question, I'm unsure of what you're after. _________________ Bill Weckel
ShinobiSoft Software
"The way is known to all, but not all know it." |
|
| Back to top |
|
 |
vtol Valued Contributor


Joined: 05 Feb 2004 Posts: 656 Location: Eastern Indiana
|
Posted: Mon Sep 24, 2007 6:07 am Post subject: |
|
|
Thanks for that ShinobiSoft
I dont know if the VDSconsole DSU would take care of this or not. |
|
| Back to top |
|
 |
Garrett Moderator Team
Joined: 04 Oct 2001 Posts: 2149 Location: A House
|
Posted: Mon Sep 24, 2007 6:10 am Post subject: |
|
|
Would the DOS environmental hold that info? _________________ 'What you do not want done to yourself, do not do to others.' - Confucius (550 b.c. to 479 b.c.) |
|
| Back to top |
|
 |
vtol Valued Contributor


Joined: 05 Feb 2004 Posts: 656 Location: Eastern Indiana
|
Posted: Mon Sep 24, 2007 7:57 am Post subject: |
|
|
| yes, but I read somewhere where DOS will not let you get it by way of batch file, but maybe that was NT, cant remember. |
|
| Back to top |
|
 |
Hooligan VDS Developer


Joined: 28 Oct 2003 Posts: 480 Location: California
|
Posted: Mon Sep 24, 2007 2:42 pm Post subject: |
|
|
Hi Vtol,
In a DOS batch you can use %SYSTEMROOT% to return the directory that windows is installed in. To get a directory listing of the system32 directory you would create the following batch:
dir %SYSTEMROOT%\system32
pause
The VDS equivilent is: @env(SYSTEMROOT)"\system32"
I hope that helps,
Hooligan _________________ Hooligan
Why be normal? |
|
| Back to top |
|
 |
vdsalchemist Admin Team

Joined: 23 Oct 2001 Posts: 1448 Location: Florida, USA
|
Posted: Mon Sep 24, 2007 3:06 pm Post subject: |
|
|
| vtol wrote: | Thanks for that ShinobiSoft
I dont know if the VDSconsole DSU would take care of this or not. |
Wow someone is actually wanting to use my VDSConsole DSU? If you need any help with that I am here. Basically you have full access to everything VDS. You should be able to use the @WINDIR(S) even if the VDS Exe is compiled as a Win32 console application. _________________ Home of
Give VDS a new purpose!
 |
|
| Back to top |
|
 |
vtol Valued Contributor


Joined: 05 Feb 2004 Posts: 656 Location: Eastern Indiana
|
Posted: Tue Sep 25, 2007 10:19 pm Post subject: |
|
|
Thanks Hooligan
Thats the one I thought I saw somewhere in the past but thought I was dreaming
| Quote: | | Wow someone is actually wanting to use my VDSConsole DSU? If you need any help with that I am here. Basically you have full access to everything VDS. You should be able to use the @WINDIR(S) even if the VDS Exe is compiled as a Win32 console application. |
I think thousands use it, but some are dumb like me and need a couple of DOS examples of it to be able to start putting it to use.
Thank both for your great help... |
|
| Back to top |
|
 |
DaveR Valued Contributor


Joined: 03 Sep 2005 Posts: 413 Location: Australia
|
Posted: Wed Sep 26, 2007 7:58 am Post subject: |
|
|
| vtol wrote: | I think thousands use it, but some are dumb like me and need a couple of DOS examples of it to be able to start putting it to use. |
I doubt anyone even knowa where to get it!?!? _________________ cheers
Dave |
|
| Back to top |
|
 |
vdsalchemist Admin Team

Joined: 23 Oct 2001 Posts: 1448 Location: Florida, USA
|
Posted: Thu Sep 27, 2007 12:04 pm Post subject: |
|
|
| DaveŽ wrote: | | vtol wrote: | I think thousands use it, but some are dumb like me and need a couple of DOS examples of it to be able to start putting it to use. |
I doubt anyone even knowa where to get it!?!? |
You can get my VDSCons DSU from here
http://www.vdsworld.com/search.php?view_mode=fileinfo&file_id=482
Also I might note that if your not browsing the main page of VDSWorld.com then you are missing a lot of good software. I noticed that there is not many using the rating system much anymore  _________________ Home of
Give VDS a new purpose!
 |
|
| Back to top |
|
 |
vtol Valued Contributor


Joined: 05 Feb 2004 Posts: 656 Location: Eastern Indiana
|
Posted: Thu Sep 27, 2007 10:48 pm Post subject: |
|
|
I allready have it for awhile and just read the help files again and cant find any overview or overall description or examples of what its used for or what I would want to use it for, I think I was at your forum once and it could be used for running old commedore 64 games like Bould Dash.
But I would enjoy more simple example of what you could use the VDSconsole for with VDS5. I'm sure its good for thousands of things  |
|
| Back to top |
|
 |
vdsalchemist Admin Team

Joined: 23 Oct 2001 Posts: 1448 Location: Florida, USA
|
Posted: Thu Oct 04, 2007 5:16 pm Post subject: |
|
|
| vtol wrote: | I think I was at your forum once and it could be used for running old commedore 64 games like Bould Dash.
|
It's not specifically for running old games It allows you to change your VDS application into a Windows 32bit console application. This could be good for such things as login scripts or programs that are command line driven where you normally would not see a GUI interface. This way you could offer both a GUI and console version of a utility. If I get some time I will build a few more examples. _________________ Home of
Give VDS a new purpose!
 |
|
| Back to top |
|
 |
vtol Valued Contributor


Joined: 05 Feb 2004 Posts: 656 Location: Eastern Indiana
|
Posted: Thu Oct 04, 2007 6:29 pm Post subject: |
|
|
OK, thanks (but no hurry if too busy - when ever)...
ya it seems we talked about it being able to do stuff at XPwindows preload
but will not run in true DOS.
But XP DOS commands lines would be good for another VDS program to run the console I think
I dont know, hee hee.
I'm just spitting words ro see where they splatter I guess  |
|
| Back to top |
|
 |
|