TNTLauncher

The TNTLauncher is an application launcher which,prior to launching an application sets the My Documents in windows to a location specified by the user.

The TNTLauncher takes the following parameters in order (enclose in" if the name contain spaces):

  • Application to launch (fully qualified name, eg. c:\temp\note.exe)
  • Temporary location of My Documents
  • Working directory
  • Parameters for the application

The only required parameter is the Application name and it is the only one given the "My Documents" and  working directory will be set to the application path. eg. if you give c:\temp\note.exe as application they will be set to c:\temp.

To give the application parameters you must specify all of the other 3 parameters for application name, My Documents and Working directory.

Example:

TNTlauncher c:\windows\notepad.exe "c:\program files documents"

The above will launch notepad with "c:\program files documents" as My Documents and c:\windows\ as working directory.

Before the launcher starts the specified application it will place a shortcut on your desktop called ResetMyDocuments which when launched will reset your My Documents to the value it had prior to using the launcher and the delete the shortcut.

The shortcut will not be overwritten if you use the launcher several times in a row.

Another option for the launcher is to give it a file as only parameter.

The launcher accepts files of the type .tnt . A .tnt file is a text file containing a line for each parameter you wish to give the launcher eg.

-------------- c:\test\sample.tnt -------------------------
c:\windows\notepad.exe
c:\program files\documents
c:\windows
myfile.txt

-------------- c:\test\sample.tnt --------------------------

if the launcher is then called with TNTLauncher c:\test\sample.tnt it will try to launch notepad with c:\program files\documents as My Documents and a working directory of c:\windows with the parameter myfile.txt.

Note that you don't have to enclose parameters with spaces in " when using a .tnt file.

If for some reason the ResetMyDocuments shortcut fails to reset your My Documents (lot's of checks to preventing this built in) you can specify the following parameters with the launcher

  • /Reset <desired location of my documents>.

Will set the location of My Documents to the location specified after /reset Remember to enclose in " if the location contains spaces.

  • /Default

This will reset My Documents to the Windows default of %USERPROFILE%\My Documents.

If the above also fails you must manually reset your My Documents by using regedit by selecting Run from the start menu and type regedit followed by enter. Then navigate to HKEY_LOCAL_MACHINE\Software\ Microsoft\Windows\Currentversion\Explorer\ User Shell Folders, double click on "Personal" and enter the location for your My Documents, if in doubt type in the default value of "%USERPROFILE%\My Documents" without the "s.

Grab the software here.

 

 

2007-02-11: Latest TNTLauncher is v. 1.00

CasualCoders.com - Simple Software Solutions