找回密码
 立即注册
搜索
热搜: 活动 交友 discuz
首页论坛EAHub 外汇论坛
查看: 27|回复: 0

WindowPriceMax( )【窗口篇-MQL4函数】

[复制链接]

4万

主题

54

回帖

4万

积分

管理员

积分
45954
发表于 2026-8-27 11:15:00 | 显示全部楼层 |阅读模式
double WindowPriceMax( void index)

返回当前图表指定子窗口的最大垂直标度的值(0为主菜单图表,指标子窗口的开始数字为1 )。 如果子窗口没有指定,最大价格标度的值返回图表窗口。

参见 WindowPriceMin(), WindowFirstVisibleBar(), WindowBarsPerChart()


参数:

index   -   图表子窗口索引 (0 -主图表窗口)。


示例:

double   top=WindowPriceMax();
double   bottom=WindowPriceMin();
datetime left=Time[WindowFirstVisibleBar()];
int      right_bound=WindowFirstVisibleBar()-WindowBarsPerChart();
if(right_bound<0) right_bound=0;
datetime right=Time[right_bound]+Period()*60;
//----
ObjectCreate("adding_rect",OBJ_RECTANGLE,0,left,top,right,bottom);
ObjectSet("adding_rect",OBJPROP_BACK,true);
ObjectSet("adding_rect",OBJPROP_COLOR,Blue);
WindowRedraw();复制代码
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|Archiver|手机版|小黑屋|EAHub外汇论坛

GMT+8, 2026-10-10 07:31 , Processed in 0.104399 second(s), 19 queries .

Powered by Discuz! X3.5

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表