MQL4 Reference
Window functions
WindowPriceOnDropped
| double WindowPriceOnDropped( |
) |
Returns the price part of the chart point where expert or script was dropped.
This value is only valid if the expert or script was dropped by mouse.
Note: For custom indicators, this value is undefined.
Sample:
double drop_price=WindowPriceOnDropped();
datetime drop_time=WindowTimeOnDropped();
//---- may be undefined (zero)
if(drop_time>0)
{
ObjectCreate("Dropped price line", OBJ_HLINE, 0, drop_price);
ObjectCreate("Dropped time line", OBJ_VLINE, 0, drop_time);
}
|
|
|