Page 1 of 1

Running tools with arguments that strip file extensions

Posted: Mon Jun 30, 2008 11:54 pm
by Elomis
Hey guys,
I use textpad for typesetting LaTeX files (as well as everything else) and have a tool that means if I press ctrl+4 it runs a program with the current file as an argument -- that's in the tools settings as $File.

The process of turning a LaTeX file into a pdf is two or three steps, what I'd like to do is be able to run a second program with the current file as the argument but EXCLUDING the three letter extension. That way I can go from my editor to a finished PDF by just typing ctrl+4, ctrl+5, ctrl+6. Is there a way of referring to $File without the extension?

Posted: Tue Jul 01, 2008 12:38 am
by talleyrand
Tool Parameter Macro is what you can look under in the help menu.

$BaseName will return the filename, sans extension
$FileDir will return the drive and letter of the filename

Happy latex/dvips/latex2pdf'ing ;)