Einzelnen Beitrag anzeigen
  #14 (permalink)  
Alt 04.05.18
Angel Angel ist offline
Mitglied
 
Registriert seit: Dec 2017
Ort: 76891
Beiträge: 126
Angel befindet sich auf einem aufstrebenden Ast
Standard

So, nun mal das komplette Prog in MQL4. Ich bekomme nicht einmal ein Rechteck angezeigt... Hier für EMA 2 und 4 auf M1 (Zu Testzwecken ):

PHP-Code:
#property copyright "Angel"
#property link      "https://www.mql5.com"
#property version   "1.00"
#property indicator_chart_window
datetime time1,time2;
         
//+------------------------------------------------------------------+
//| Expert initialization function                                   |
//+------------------------------------------------------------------+
void OnInit()
  {  
   
ObjectsDeleteAll();
  }
//+------------------------------------------------------------------+
//| Expert deinitialization function                                 |
//+------------------------------------------------------------------+
void OnDeinit(const int reason)
  {
  
ObjectsDeleteAll();
  }
//+------------------------------------------------------------------+
//| Expert tick function                                             |
//+------------------------------------------------------------------+
int start()
  {               

double EMA10_1 iMA(NULL210101); // "NULL"= (Current Chart) , Timeframe , Periode ("0"=Current , "1"=M1 usw), MA_Shift , MA_Method ("0"=SMA,"1"=EMA usw) , Enum_Applied_Price ("0"=Close , "1"=Open usw) , shift)
double EMA10_2 iMA(NULL410102);
double EMA20_1 iMA(NULL210101);
double EMA20_2 iMA(NULL410102);

if (
EMA10_2 EMA20_2 && EMA10_1 EMA20_1)  time1 Time[1];  
if (
EMA10_2 EMA20_2 && EMA10_1 EMA20_1)  time1 Time[1];

{

ObjectCreate(0,"Rechteck",OBJ_RECTANGLE,0,Time[1],1.19100,Time[1],1.20100);
ObjectSetInteger(0,"Rechteck",OBJPROP_COLOR,clrBlueViolet );
ObjectSetInteger(0,"Rechteck",OBJPROP_WIDTH,);
ObjectSetInteger(0,"Rechteck",OBJPROP_SELECTABLE,true);
ObjectSetInteger(0,"Rechteck",OBJPROP_BACK,true); 
}

return(
0);      

__________________
MQL4-Interessiert... und noch gaaaanz am Anfang