PowerSurge Publishing

 

Products | Twodue | Operating Guide | General

Web Scripts

Web publishing can also be done by executing a script file. A script file actually executes TDF Czar (a separate program described on the PowerSurge Web Site). The script file may contain a series of commands that can sort and filter your list in multiple ways, and create Web Pages using multiple templates. A script file is identified by the file extension ".tcz". The script file is itself a tab-delimited text file, and you can edit one using your favorite tool for such things. Two Due does not include the capability of recording a script file for you automatically, but TDF Czar does.

The script file has the following columns.

  1. module -- This names the tab to process the command.
  2. action -- This names the action to be taken, and usually corresponds to a button on a tab.
  3. modifier -- This supplies a value that modifies the intent of the command in some way.
  4. object -- The name of the thing to be acted upon.
  5. value -- A value that the object is to be set equal to.

Following is a complete list of all the allowable forms for script commands. Constants are displayed in normal type. Variables appear in italics. Blank cells indicate fields that are not applicable to a particular command, and therefore can be left blank or empty. Forward slashes are used to separate alternate values: only one of them must appear (without the slash) in an actual script command. Most of the values correspond directly to equivalent buttons on the tabs, as described elsewhere in this user guide. The one non-intuitive value is probably the Filter values for the andor object: True sets "and" logic on, while False sets "or" logic on.

Note that file names may begin with the literal "PATH" surrounded by "#" symbols. When recording a script, the program will automatically replace the path containing the script file with this literal. In addition, upwards references from the location of the script file will be indicated by two consecutive periods for each level in the folder hierarchy. On playback, the reversing decoding will occur. In effect this means that files within the same path structure as the script file, or a sub-folder, will have their locations identified relative to the location of the script file. Files on a completely different path will have their locations identified with absolute drive and path information. The overall effect of this is to make a script file, along with the input files referenced by the script file, portable packages that can be moved from one location to another, or executed with different drive identifiers, and still execute correctly. Normally all of this will be transparent to the user.

module action modifier object value
input open url merge/blank url name
input open file merge/blank file name
input open dir merge/blank directory name
input open html1 merge/blank file name
input open html2 merge/blank file name
input open html3 merge/blank file name
sort add Ascending/ Descending field name  
sort clear      
sort set   params  
combine add   dataloss integer
0 = no data loss, 1 = one record overrides, 2 = allow concatenation
combine add   precedence integer
+1 = later overrides earlier, -1 = earlier overrides later
combine add   minnoloss integer
combine set   params  
filter set   andor True/ False
filter add operator field name comparison value
filter clear      
filter set   params  
output set   usedict True/ False
output open     file name
template open file   file name
template generate      

 

Home | Downloads | Donations | Store | Support | Products

Copyright © 1999-2008 Herb Bowie • All rights reserved • E-mail:

http://www.powersurgepub.com/ | script.html | Revised: 7/23/08

Google
WWW PowerSurgePub.com