SetTraceFileName
PowerScript function
Description
Specifies the name of the trace file PowerBuilder will analyze when
the BuildModel function is called.
Applies to
Profiling and TraceTree objects
Syntax
|
1 |
instancename.SetTraceFileName ( tracefilename ) |
|
Argument |
Description |
|---|---|
|
instancename |
Instance name of the Profiling or TraceTree object |
|
tracefilename |
A string that identifies the name of the trace file |
Return value
ErrorReturn. Returns one of the following values:
-
Success! — The function succeeded
-
FileOpenError! — The file could not be opened
-
FileInvalidFormatError! — The trace file is not in the correct
format -
ModelExistsError! — A model has already been built
If an error occurs, the name is not set.
Usage
Use this function to specify the trace file PowerBuilder should
analyze with the BuildModel function. You call the SetTraceFileName
function before calling the BuildModel function.
Examples
This example provides the name of the trace file for which a
performance analysis model is to be built:
|
1 2 3 4 5 6 7 8 9 10 11 12 13 |
Profiling lpro_model String ls_line lpro_model = CREATE Profiling lpro_model.SetTraceFileName (filename) ls_line = "CollectionTime = " + & String(lpro_model.CollectionTime ) + "~r~n" & + "Num Activities = " & + String(lpro_model.NumberOfActivities) + "~r~n" lpro_model.BuildModel() ... |
See also