Go Back   Technology Questions > Software Questions > Operating System Questions > Windows XP

Windows XP Discuss the Microsoft Windows XP Operating System

Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old 03-05-2007, 02:45 PM
Dick Watson
Tablet PC Guest
 
Posts: n/a
executable for cmd not in path?

I'm trying to add an external command line utility (fsum.exe from slavasoft)
to a WinXP system but do not want to just dump the executable in
%SystemRoot%\system32 for reasons of traceability as to how all of the
add-in stuff like this got on the system. But I also don't want to add
%ProgramFile%\misc\fsum (wherein I document the source of the code, etc) to
the system environment path in order to avoid the path getting any more out
of hand than it already is and to avoid adding lots of directories (where
anything will be run from) to the path when I just want to be able to find
one specific executable.

I've tried creating a .lnk in %SystemRoot%, but cmd doesn't follow these.
I've tried registering
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Curr entVersion\App
Paths\fsum.exe with a default REG_EXPANS_SZ pointing to the executable, but
cmd also appears to ignore these.

What is the "best practice" way to get a specific external command in the
path? Just put a copy of the executable in %SystemRoot% or
%SystemRoot%\system32?


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

 
Old 03-05-2007, 02:45 PM
Xploder HD Movie Player for PS3. Manage, convert and transfer media files between the PC and PS3.
  #2 (permalink)  
Old 03-05-2007, 03:00 PM
Ayush
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

Dick Watson wrote ::
> I'm trying to add an external command line utility (fsum.exe from slavasoft)
> to a WinXP system but do not want to just dump the executable in
> %SystemRoot%\system32 for reasons of traceability as to how all of the
> add-in stuff like this got on the system. But I also don't want to add
> %ProgramFile%\misc\fsum (wherein I document the source of the code, etc) to
> the system environment path in order to avoid the path getting any more out
> of hand than it already is and to avoid adding lots of directories (where
> anything will be run from) to the path when I just want to be able to find
> one specific executable.



Create a .bat or .cmd file in one of the folders listed in paths and use
the bat file to launch your exe with params.

Bat Ex:
start /d"C:\Program Files\misc\fsum" fsum.exe "%1" "%2" "%3" "%4" "%5"



Good Luck, Ayush.
--
XP-Tips [Adjust the vertical space between icons] :
http://www.microsoft.com/windowsxp/u...iconspace.mspx
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #3 (permalink)  
Old 03-05-2007, 03:15 PM
Dave Patrick
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

What process calls it? Why not call it using the fully qualified path?

%ProgramFile%\misc\fsum.exe

--

Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

"Dick Watson" wrote:
> I'm trying to add an external command line utility (fsum.exe from
> slavasoft) to a WinXP system but do not want to just dump the executable
> in %SystemRoot%\system32 for reasons of traceability as to how all of the
> add-in stuff like this got on the system. But I also don't want to add
> %ProgramFile%\misc\fsum (wherein I document the source of the code, etc)
> to the system environment path in order to avoid the path getting any more
> out of hand than it already is and to avoid adding lots of directories
> (where anything will be run from) to the path when I just want to be able
> to find one specific executable.
>
> I've tried creating a .lnk in %SystemRoot%, but cmd doesn't follow these.
> I've tried registering
> HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Curr entVersion\App
> Paths\fsum.exe with a default REG_EXPANS_SZ pointing to the executable,
> but cmd also appears to ignore these.
>
> What is the "best practice" way to get a specific external command in the
> path? Just put a copy of the executable in %SystemRoot% or
> %SystemRoot%\system32?
>


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #4 (permalink)  
Old 03-05-2007, 03:45 PM
Dick Watson
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

Typing in a cmd shell. That's why forcing the user to use a hard path is not
really attractive.

"Dave Patrick" <DSPatrick@nospam.gmail.com> wrote in message
news:4E9C98CF-DA1C-49CE-AFA1-18A2AF29D534@microsoft.com...
> What process calls it? Why not call it using the fully qualified path?
>
> %ProgramFile%\misc\fsum.exe



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #5 (permalink)  
Old 03-05-2007, 04:00 PM
Dick Watson
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

This is probably the best approach. But I' want to use %* so that I can pass
all the params without regard to how many there are.

Great idea! It hadn't even occurred to me... Thanks!

"Ayush" <"ayushmaan.j[aatt]gmail.com"> wrote in message
news:eNaAzl3XHHA.4232@TK2MSFTNGP05.phx.gbl...
> Dick Watson wrote ::
>> I'm trying to add an external command line utility (fsum.exe from
>> slavasoft) to a WinXP system but do not want to just dump the executable
>> in %SystemRoot%\system32 for reasons of traceability as to how all of the
>> add-in stuff like this got on the system. But I also don't want to add
>> %ProgramFile%\misc\fsum (wherein I document the source of the code, etc)
>> to the system environment path in order to avoid the path getting any
>> more out of hand than it already is and to avoid adding lots of
>> directories (where anything will be run from) to the path when I just
>> want to be able to find one specific executable.

>
>
> Create a .bat or .cmd file in one of the folders listed in paths and use
> the bat file to launch your exe with params.
>
> Bat Ex:
> start /d"C:\Program Files\misc\fsum" fsum.exe "%1" "%2" "%3" "%4" "%5"
>
>
>
> Good Luck, Ayush.
> --
> XP-Tips [Adjust the vertical space between icons] :
> http://www.microsoft.com/windowsxp/u...iconspace.mspx



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #6 (permalink)  
Old 03-05-2007, 04:15 PM
Dave Patrick
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

Forcing the user to a command prompt in-of-itself might be a problem. Why
not create a shortcut? If you need the window kept open then;

cmd /k %ProgramFile%\misc\fsum.exe

--

Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

"Dick Watson" wrote:
> Typing in a cmd shell. That's why forcing the user to use a hard path is
> not really attractive.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #7 (permalink)  
Old 03-05-2007, 04:15 PM
Dick Watson
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

Without the parameters, fsum is useless. Short of putting a whole UI on it,
it's really just an external command. The users are people like me who don't
mind typing commands.

"Dave Patrick" <DSPatrick@nospam.gmail.com> wrote in message
news:e1OoYJ4XHHA.4440@TK2MSFTNGP03.phx.gbl...
> Forcing the user to a command prompt in-of-itself might be a problem. Why
> not create a shortcut? If you need the window kept open then;
>
> cmd /k %ProgramFile%\misc\fsum.exe



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #8 (permalink)  
Old 03-05-2007, 04:30 PM
Ayush
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

Dick Watson wrote ::
> This is probably the best approach. But I' want to use %* so that I can pass
> all the params without regard to how many there are.
>
> Great idea! It hadn't even occurred to me... Thanks!



You are welcome.



Good Luck, Ayush.
--
Google Groups: http://groups.google.com/
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #9 (permalink)  
Old 03-05-2007, 04:30 PM
Dave Patrick
Tablet PC Guest
 
Posts: n/a
Re: executable for cmd not in path?

OK, gotcha. You could probably capture the arg string using input box with
VBScript and call it that way.

--

Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

"Dick Watson" wrote:
> Without the parameters, fsum is useless. Short of putting a whole UI on
> it, it's really just an external command. The users are people like me who
> don't mind typing commands.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Executable Paka Windows Vista 2 03-02-2007 07:00 AM
Any way to tell if wmv file contains executable code? janedough250164@dontsendhotmail.com Windows XP 3 02-22-2007 02:01 PM
Watch an executable file? weeniejeff@gmail.com Windows XP 0 01-14-2007 02:46 PM
Time Executable error Ollakal Windows XP 1 01-04-2007 06:51 AM
Time Executable - Windows XP Ollakal Windows XP 6 01-04-2007 05:22 AM


All times are GMT -8. The time now is 02:00 AM.


2003 - 2008 All Rights Reserved. Technology Questions

SEO by vBSEO 3.1.0