Trade dialog

The value dialog Trade is used to create a button that allows to open the dialog for a trade selection.

../../../../_images/Trade.png

Clicking the button opens the trade dialog like

../../../../_images/TradeDialog.png

After closing the dialog, the name of the selected trade is displayed as the button text and the ID is assigned to the parameter.

Syntax

<Parameter>
<Name>TradeID</Name>
<Text>Trade</Text>
<Value>0</Value>
<ValueType>Integer</ValueType>
<ValueDialog>Trade</ValueDialog>
</Parameter>

Optional tags

If the PythonPart should be localized, the following tag must be added

<TextId>1001</TextId>

Sometimes it’s useful to disable or hide the button depending on the value of another parameter. This is achieved by adding additional tags to the parameter or by defining functions in the py-file. See Enable and visible options

The persistent state of the parameter can be changed by adding

<Persistent></Persistent>

Example

The implementation of the Trade value dialog is described in the example AllControls located in

..\etc\Examples\PythonParts\PaletteExamples\AllControls.pyp
..\etc\PythonPartsExampleScripts\PaletteExamples\AllControls.py