Send order information about an order's reason to the Trade Log report, and so it appears in the Trade Log list below the chart area.
Syntax: |
---|
order.SetRuleLabel( ruleLabel ) |
Parameter: |
Description: |
---|---|
ruleLabel |
Text description of the rule that created the order. |
Returns: |
---|
Rule Labels assigned will appear in the Trade Log report. |
Example: |
---|
' ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
' ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ' Printing order.ruleLabel after assignment: Print "order.ruleLabel = ", order.ruleLabel |
Results: |
order.ruleLabel = Lx@100.35s |
Access to Order Object properties and functions in other scripts is made possible by using the AlternateOrder Object as the prefix ahead of the "." property or function. AlternateOrder Object is discussed below.
Notes: |
---|
Always check to be sure the order is available after a Broker function call using the system.orderExists() function prior to accessing it.
Using the alternateOrder object when orders are not in context will provide the same access as the Order object. However, the alternateOrder object must be brought into context using the system.SetAlternateOrder object function prior to any attempt to use is properties and functions.
Once orders are brought into context their properties and function are available to reference and changes. |
Links: |
---|
Max, OrderExists, position, PriceFormat, RoundTick, SetExitStop, SetOrderReportMessage |
See Also: |
AlternateOrder Object, AlternateSystem Object, Order Functions, Order Object, Order Properties |
Edit Time: 10/23/2020 11:43:45 AM |
Topic ID#: 554 |