|
||||
|
|
||||
|
PC Access for Windows Reference Guidefor PC Access Version 4.30![]() ![]() ![]()
Script Command: sendtodayFormat: sendtoday {format "date format"} {offset n}; This command sends the current date to the host. You may specify the format of the date text with "date format". You may send a date other than the current date by using offset n, where n is in the units of days and may be a positive or negative signed integer. The "date format" defaults to MM/DD/YY. The PC Access script command processor will scan your "date format" and substitute numerical date components as follows: · MM (month); example: 02 · DD (day of month); example: 28 · YY (two-digit year); example: 99 · YYYY (four-digit year); example: 1999 · MFM has tested this command and found it to work with year values of 2000 and above. The script command processor will send all other characters in "date format" to the host exactly as you type them. Normally these other characters will be delimiters between numerical date components. Examples: // Send the word "Hello" to the host: sendtoday format "MM-DD-YYYY"; sendtoday format "YY-MM-DD"; sendtoday format "Today is the MM month, DD day of the year YYYY"; sendtoday format "MM-DD-YY" offset 2; // Two days from now sendtoday format offset -7; // One week ago The sendtoday command may be useful in an auto-login script you execute via delayed dialing. This enables your script to supply the current date each time it runs to any command on the host that expects a date. You may conveniently insert a sendtoday command while you are recording a script by selecting the Script | Send a Date... menu item on the Terminal window. This opens the Send a Date Relative to Today window where you may edit the sendtoday command parameters. This topic is new for PC Access 4.30.
![]() ![]() ![]()
| |||