f$TraceFile (f$ProtokollDatei)
f$TraceFile (f$ProtokollDatei)
This function causes ePOS to write all actions executed after this function into a trace file. A tab-delimited text file is created as the trace file. This file can be read most clearly in Excel. .txt is suggested as the file extension. The name of the decision table, the action executed and its text are included in the trace file. Furthermore, the start, end, and decision table condition met are written into the trace file. The values of ePOS parameters can be produced additionally, if desired.
Syntax: | Status = f$TraceFile ( 'Filename' , usage , 'Parameternames' ) | ||
| Argument | Type | Meaning |
| File name | String | Name of the trace file or '' to finish writing the trace file |
| Usage | Integer | This parameter specifies if the trace file also logs the execution of the decision tables in metalanguage. 0 – without metalanguage 1 – metalanguage DT call is included in trace file 2 – entire metalanguage DT is included in trace file |
| Parameternames | String | Comma-separated list of ePOS parameters whose values are to be produced in the trace file. |
Result: | Integer | 0 – file created -1 – the file could not be created Possible reasons: Incorrect path, file is open, insufficient permissions | |
Examples: | smp_status = f$tracefile ('E:\\temp\\std_print1.txt', 1,'status,wk1.MaterialID, textline') or file name = 'E:\\temp\\std_print1.txt' smp_status = f$tracefile (Filename, 1,'status,wk1.MaterialID, textline') | ||
Extract from the trace file:
Start | std_print:documents:start | Depth | Start:11.06.10 11:44:21 | status | wk1.MaterialID | textline |
Start | std_print:offer:item (1) | 5 |
| 0 | 15 |
|
| std_print:offer:item | 5 | (R4): i > head.SumItems && wk[i].StlLevel < i_level && wk[i].StlLevel > i_level && wk[i].MaterialSaleLevel == 1 && wk[i].MaterialSaleType && smtext.Outputform && wk[i].StlLevel | 0 | 15 |
|
| std_print:offer:item | 5 | (R4:A1): f$PGCopy(’wk[i]’,’wk1’) | 0 | 15 |
|
| std_print:offer:item | 5 | (R4:A2): Quantity = wk1.Quantity * wk1.SaleFactor | 0 | 16 |
|
| std_print:offer:item | 5 | (R4:A3): p$a_menge() | 0 | 16 |
|
Start | std_print:offer:a_quantity () | 6 |
| 0 | 16 |
|
| std_print:offer:a_quantity | 6 | (R2): Else | 0 | 16 |
|
End | std_print:offer:a_quantity | 6 |
| 0 | 16 |
|
| std_print:offer:item | 5 | (R4:A4): i_level_gl = i_level | 0 | 16 |
|