bool OrderCloseBy(int ticket, int opposite, color Color_CLR_NONE)
Closes an opened order by another opposite opened order. If the function succeeds, the return value is true. If the function fails, the return value is false. To get the detailed error information, call GetLastError().
別の反対保有したオーダーによって、保有したオーダーを閉じます。この関数が正常終了した場合、戻り値は TURE です。この機能が失敗した場合は、戻り値は
FALSE です。詳細なエラー情報を取得するには、GetLastError()
を呼び出します。
Parameters:
パラメータ:
| ticket |
- |
Unique number of the order ticket. オーダーチケットの一意の番号。 |
| opposite |
- |
Unique number of the opposite order ticket. 反対のオーダーチケットの一意の番号。 |
| Color |
- |
Color of the closing arrow on the chart. If the parameter is
missing or has CLR_NONE value closing arrow will not be drawn on the
chart.
チャート上の決済した矢印の色。もし、パラメータが欠けているか、CLR_NONE 値をもっている場合は、決済した矢印はチャート上に表示されません。 |
|
Sample:
サンプル:
if(iRSI(NULL,0,14,PRICE_CLOSE,0)>75)
{
OrderCloseBy(order_id,opposite_id);
return(0);
}
|