LogMsg
3min
Logs message to a text file.
The file has to be specified prior by the LogFile command.
LogMsg "<message text>"
Parameters
- message text parameter specifies the message to be displayed
- if variable numbers are included outside of quotation marks, this results in the value of that variable being appended to the message e.g. Msg "value of variable 4000 is " #4000
- if %t... is included outside of quotation marks, this results in the tool description of the tool number being appended to the message e.g. Msg "T1 is " %t1 or msg "Current tool: " %t#5011
- if %d is included outside of quotation marks, this results in the current date and time being appended to the message e.g. Msg "Time: "%d will output Time: 2022-10-28 13:35:52
Example
LogFile "text.txt" 1
LogMsg "Current position of X is "#5001
Now check the contents of file text.txt will now contain Msg, LogMsg, WarnMsg, ErrMsg can now use %txx (xx = 0-99) and this will show the tool description text. Example: msg %t#5011 " is changed to "Tool number 5" this is text from the tool table.