[存档!]任何菜鸟问题,为了不使论坛变得混乱。专业人士,不要路过。没有你,哪里都不能去 - 4. - 页 38

 
evillive:

那么,这里是https://www.mql5.com/ru/forum/106619

Windows任务调度器,允许你按计划或通过信号做一些事情,如发送邮件、运行应用程序/脚本/按钮等。

谢谢,我会试一试的。我希望我的脚本也能对某人有用。现在我希望我可以在内存中创建一个虚拟文件,而不是一个真实的文件,然后运行它,然后一切都在EA中......虽然,这是一种奢侈的行为...
 
还有EXP_Relogin 顾问。
 
下午好。你能告诉我如何优化EA,以便在美分账户上交易吗?
 

早晨好!

你能告诉我如何检查市场订单的开仓和平仓吗?

谢谢你。

 
大家下午好!
问题如下,第一次启动指标时显示的是
通过alphabra-cadabra(pic.1)。在进一步滚动历史记录后,一切正常(图2)。

你能告诉我问题出在哪里吗? 如果你需要代码,请在下面。

#property indicator_separate_window
#property  indicator_buffers 3
#property  indicator_color1  Tomato
#property  indicator_color2  Red
#property  indicator_color3  Blue
#property indicator_level1 0
#property indicator_levelcolor Gray
#property indicator_levelstyle 2

extern int Period_MA = 5;
extern int MA_Line1 = 13;
extern int MA_Line2 = 34;
 
double Brs[],BrsMA1[],BrsMA2[],MathArr[],MathArr1;
int i=0,j=0;
double hvostUp,hvostDn,rast,S;

//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int init()
  {
//---- indicators
   SetIndexBuffer(0,Brs);
   SetIndexStyle(0,DRAW_HISTOGRAM);
   SetIndexBuffer(1,BrsMA1);
   SetIndexStyle(1,DRAW_LINE);
   SetIndexBuffer(2,BrsMA2);
   SetIndexStyle(2,DRAW_LINE);
   SetIndexLabel(0,"Bars_");
   SetIndexLabel(1,"Bars_MA1");
   SetIndexLabel(2,"Bars_MA2");
     
   ArrayResize(MathArr,Period_MA);
   
 //---- name for DataWindow and indicator subwindow label
   IndicatorShortName("Bars_MA");

   return(0);
  }
//+------------------------------------------------------------------+
//| Custom indicator deinitialization function                       |
//+------------------------------------------------------------------+
int deinit(){return(0);}
//+------------------------------------------------------------------+
//| Custom indicator iteration function                              |
//+------------------------------------------------------------------+

int start() {  

int ncount=IndicatorCounted();
int limit=Bars-ncount-1;

for (int i=0; i<limit; i++)
{

if (High[i+2]>High[i+1] && Low[i+2]>Low[i+1])
{
hvostUp=(High[i+2]-High[i+1])/Point;
hvostDn=(Low[i+2]-Low[i+1])/Point;
rast=(High[i+2]-Low[i+1])/Point;
S=rast-hvostUp-hvostDn;
}

if (High[i+2]<High[i+1] && Low[i+2]<Low[i+1])
{
hvostUp=(MathAbs(High[i+2]-High[i+1]))/Point;
hvostDn=(MathAbs(Low[i+2]-Low[i+1]))/Point;
rast=(High[i+1]-Low[i+2])/Point;
S=rast-hvostUp-hvostDn;
}

if (High[i+2]>=High[i+1] && Low[i+2]<=Low[i+1])
{
S=(High[i+1]-Low[i+1])/Point;
rast=(High[i+2]-Low[i+2])/Point;
}

if (High[i+2]<=High[i+1] && Low[i+2]>=Low[i+1])
{
S=(High[i+2]-Low[i+2])/Point;
rast=(High[i+1]-Low[i+1])/Point;
}

if (High[i+2]<=Low[i+1] || Low[i+2]>=High[i+1])
{
S=0;
rast=1;
}

if(j>=Period_MA-1)j=0;
j++;
 MathArr[j]=(S/rast*100);
 
Brs[i]=iMAOnArray(MathArr,0,Period_MA,0,0,0);
BrsMA1[i]=iMAOnArray(Brs,0,MA_Line1,0,0,0);
BrsMA2[i]=iMAOnArray(Brs,0,MA_Line2,0,0,0);
}   
  return(0);
}

图1

图2

附加的文件:
bars_ma.mq4  4 kb
 
我想与你分享我的想法。 阅读各种外汇论坛,我看到在现场交易时,经纪公司方面会发生令人讨厌的事情。我没有见过模拟账户发生任何坏事。我有一个想法:把EA放在模拟账户上,并与我的真实账户连接,然后再与我的模拟账户连接(通过)。当然,交易中的几个点会丢失,但对于超过10个点的策略来说,这已经足够好了,而且还有可能让其他人签署使用。
 
谁来告诉我如何改写剧本!在下单时,脚本以当前的买入价 为指导,而开盘价是需要的。
 
如果能把这个过程自动化就好了,也就是说,事先做好这项工作,而不是等待利润触发。我看了看所有发布的脚本,我找到了一个类似的脚本,但他们说它不起作用。或者让我们做一个函数,当TP或SL触发时,脚本会打开所有刚刚关闭的订单,只是以挂起的形式。许多交易员知道他们在某种情况下要做什么,在情况发生之前做这些是非常方便的。
 

能否请你帮助我?如何用同样的魔法关闭5个挂单

提前感谢!

 
artem86:

能否请你帮助我?如何用同样的魔法关闭5个挂单。

提前感谢您!


在脚本中寻找,应该有一个类似的脚本。