<< Click to Display Table of Contents >> Navigation: 3. Script Language > TXT. Text-File Engine > To LOF / To Var > String-Commands * TXT-Command |
MiniRobotLanguage (MRL)
TXT.tov
TXT.To_Var
Copy the TXT.-internal Buffer into a Variable
in a internal Format, that includes additional Informations, like the Filenname
Intention
This command is used to make a complete Backup of the currently loaded Text into a Variable.
Therefore the Text can be restored using the TXT.From_Var-Command.
' Load Textfile into internal Buffer for further TXT.-Command Operations
' ($$RES is 0/1 success)
TXT.Load_Textfile|$$FIL|$$RES
' Reserve speichern
TXT.tov|$$LAD
' We have now a Backup of the Textfile in $$LAD.
' It can be restored - overwriting the current Buffer-Content using:
TXT.fov|$$LAD
Syntax
TXT.tov|P1
TXT.To_Var|P1
Parameter Explanation
P1 - (Output) Variable with the result of the operation.
On error a "" is returned also the Timeout-Flag is set.
On success, the Lenght in Bytes/Charcters of the currently loaded file is been returned.
If omitted the result is placed on TOS.
Example
'*****************************************************
' EXAMPLE 1: TXT.ltf and TXT.gtl etc.
'*****************************************************
VAR.$$LAA=?path\..\Pics\Test.txt
TXT.ltf|$$LAA|$$RES
' Reserve speichern
TXT.tov|$$LAD
' We have now a Backup of the Textfile in $$LAD.
' It can be restored - overwriting the current Buffer-Content using:
TXT.fov|$$LAD
ENR.
Remarks
Can acess very large pathes up to 32767 characters due to the use of NTFS-direct.
Limitations:
-
See also:
• IEF. / NEF. - If - exist - File