forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


A way to get Win system32 PATH with DOS batch or other way.

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help
View previous topic :: View next topic  
Author Message
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Mon Sep 24, 2007 4:36 am    Post subject: A way to get Win system32 PATH with DOS batch or other way. Reply with quote

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
View user's profile Send private message Visit poster's website
ShinobiSoft
Professional Member
Professional Member


Joined: 06 Nov 2002
Posts: 790
Location: Knoxville, Tn

PostPosted: Mon Sep 24, 2007 4:54 am    Post subject: Reply with quote

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
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Mon Sep 24, 2007 6:07 am    Post subject: Reply with quote

Thanks for that ShinobiSoft

I dont know if the VDSconsole DSU would take care of this or not.
Back to top
View user's profile Send private message Visit poster's website
Garrett
Moderator Team


Joined: 04 Oct 2001
Posts: 2149
Location: A House

PostPosted: Mon Sep 24, 2007 6:10 am    Post subject: Reply with quote

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
View user's profile Send private message
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Mon Sep 24, 2007 7:57 am    Post subject: Reply with quote

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
View user's profile Send private message Visit poster's website
Hooligan
VDS Developer
VDS Developer


Joined: 28 Oct 2003
Posts: 480
Location: California

PostPosted: Mon Sep 24, 2007 2:42 pm    Post subject: Reply with quote

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
View user's profile Send private message
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Mon Sep 24, 2007 3:06 pm    Post subject: Reply with quote

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
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Tue Sep 25, 2007 10:19 pm    Post subject: Reply with quote

Thanks Hooligan Very Happy
Thats the one I thought I saw somewhere in the past but thought I was dreaming Laughing

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. Wink

Thank both for your great help...
Back to top
View user's profile Send private message Visit poster's website
DaveR
Valued Contributor
Valued Contributor


Joined: 03 Sep 2005
Posts: 413
Location: Australia

PostPosted: Wed Sep 26, 2007 7:58 am    Post subject: Reply with quote

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. Wink

I doubt anyone even knowa where to get it!?!?

_________________
cheers

Dave
Back to top
View user's profile Send private message
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Thu Sep 27, 2007 12:04 pm    Post subject: Reply with quote

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. Wink

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 Sad

_________________
Home of

Give VDS a new purpose!
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Thu Sep 27, 2007 10:48 pm    Post subject: Reply with quote

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 Cool
Back to top
View user's profile Send private message Visit poster's website
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Thu Oct 04, 2007 5:16 pm    Post subject: Reply with quote

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 Laughing 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
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Thu Oct 04, 2007 6:29 pm    Post subject: Reply with quote

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 Question
I dont know, hee hee.
I'm just spitting words ro see where they splatter I guess Cool
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group