Automate or Batch TPT scripts

Tools
N/A

Automate or Batch TPT scripts

I am trying to automate a TPT jobscript but I am having difficulty. Essentially what I would like to do is create the script using the TPT wizard and then execute it with command lines. I have tried the following:

In a command window, tbuild -f jobscript.txt > errorlog.txt, but this errors saying "Error retrieving TWB root directory"

I have found documentation on the TPT API but it seems like there should be an easy way just to execute a jobscript that was created using the wizard. Thanks in advance for the help.