Box
Download scriptThis tool is designed as a visual mapping assistant for MetaTrader 4. Its primary purpose is to automatically draw and organize complex geometric structures—such as trendlines, horizontal levels, and vertical markers—based on specific price points you define. Instead of manually clicking to place every line, this script calculates the positioning of multiple intersecting lines and "crosses" dynamically.
Here is a breakdown of how the logic functions:
Core Functionality
- Dynamic Geometric Mapping: The script identifies two primary reference points on your chart. Once these are set, it automatically calculates several secondary coordinates to create a network of trendlines, diagonal lines, and support/resistance markers.
- Timeframe Awareness: The logic is designed to be "smart" about different trading periods. It can adjust the visibility and scale of the drawn objects depending on whether you are viewing the market on a 1-minute chart, an hourly chart, or even monthly scales.
- Automated Visual Updates: Every time the chart updates, the script ensures that all lines (including vertical markers, horizontal levels, and various "cross" lines) are correctly positioned. It constantly checks if these objects exist; if they do, it refreshes their properties; if not, it creates them.
Key Features
- Customizable Visual Styles: You can control the aesthetic of the data visually without changing the logic. This includes choosing different colors for various types of lines (e.g., FireBrick, Blue, Green), adjusting line thickness, and selecting different line styles (dotted, solid, etc.).
- Multi-Layered Objects: The script handles a high volume of unique objects simultaneously:
- Vertical & Horizontal Lines: Used for marking specific time zones or price floors/ceilings.
- Trend & Diagonal Lines: These are calculated mathematically to show potential paths of price action, including "Main Crosses," "Sub-Main Crosses," and "Diagonal" markers.
- Reference Points: It places specific icons (arrows) at your chosen start and end dates to anchor the entire geometric construction.
- Time-Based Positioning: If you choose a time-based input, the script can automatically locate the correct historical bars based on specific dates provided in the settings.
Operational Logic
- Initialization & Cleanup: When first loaded (or removed), the script identifies all previous drawings associated with its unique ID to "clean" the chart, ensuring that old data doesn't clutter your current view.
- Point Identification: It looks for two specific anchors. It calculates the highest high and lowest low between these points to determine the "range" of the price action.
- Mathematical Projection: Using the range identified above, it performs calculations to project out future (or past) coordinates. This allows it to draw lines that intersect at mathematically significant points.
- Visual Rendering: Finally, it renders all components—horizontal levels, vertical markers, and trend lines—applying your preferred colors and styles to every individual piece of the geometry.
//+------------------------------------------------------------------+
//| Box.mq4 |
//| |
//| |
//+------------------------------------------------------------------+
#property copyright ""
#property link ""
#property indicator_chart_window
extern int Complect=0;
extern int timeframe=0;
extern bool over=false;
extern bool backgr=false;
extern bool stopper=false;
extern bool save=false;
extern color point_col=Blue;
extern color vlines_col=Yellow;
extern color hlines_col=Yellow;
extern color colour1=FireBrick;
extern color colour2=Blue;
extern color colour3=MediumSpringGreen;
extern int vlines_style=0;
extern int hlines_style=0;
extern int style1=0;
extern int style2=0;
extern int style3=0;
extern int point_width=1;
extern int vlines_width=1;
extern int hlines_width=1;
extern int width1=1;
extern int width2=1;
extern int width3=1;
extern int fplace=34;
extern int splace=5;
extern bool by_time=false;
extern datetime point1_date=D'2007.07.24 00:00';
extern datetime point2_date=D'2007.08.16 00:00';
extern bool handycode=false;
extern int code=108;
extern bool delpoints=false;
datetime prevtime;
//+------------------------------------------------------------------+
//| Custom indicator initialization function |
//+------------------------------------------------------------------+
int init()
{
//----
ObjectDelete("VLine1 Complect¹"+Complect);
ObjectDelete("VLine2 Complect¹"+Complect);
ObjectDelete("VLine3 Complect¹"+Complect);
ObjectDelete("VLine4 Complect¹"+Complect);
ObjectDelete("VLine5 Complect¹"+Complect);
ObjectDelete("HLine1 Complect¹"+Complect);
ObjectDelete("HLine2 Complect¹"+Complect);
ObjectDelete("HLine3 Complect¹"+Complect);
ObjectDelete("HLine4 Complect¹"+Complect);
ObjectDelete("HLine5 Complect¹"+Complect);
ObjectDelete("MainCrossLine1 Complect¹"+Complect);
ObjectDelete("MainCrossLine2 Complect¹"+Complect);
ObjectDelete("SubMainCross1Line1 Complect¹"+Complect);
ObjectDelete("SubMainCross1Line2 Complect¹"+Complect);
ObjectDelete("SubMainCross2Line1 Complect¹"+Complect);
ObjectDelete("SubMainCross2Line2 Complect¹"+Complect);
ObjectDelete("Diag1Line1 Complect¹"+Complect);
ObjectDelete("Diag1Line2 Complect¹"+Complect);
ObjectDelete("Diag1Line3 Complect¹"+Complect);
ObjectDelete("Diag1Line4 Complect¹"+Complect);
ObjectDelete("Diag2Line1 Complect¹"+Complect);
ObjectDelete("Diag2Line2 Complect¹"+Complect);
ObjectDelete("Diag2Line3 Complect¹"+Complect);
ObjectDelete("Diag2Line4 Complect¹"+Complect);
ObjectDelete("FirstCrossLine1 Complect¹"+Complect);
ObjectDelete("FirstCrossLine2 Complect¹"+Complect);
ObjectDelete("LastCrossLine1 Complect¹"+Complect);
ObjectDelete("LastCrossLine2 Complect¹"+Complect);
//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator deinitialization function |
//+------------------------------------------------------------------+
int deinit()
{
//----
if(delpoints)
{
ObjectDelete("Point1 Complect¹"+Complect);
ObjectDelete("Point2 Complect¹"+Complect);
}
ObjectDelete("VLine1 Complect¹"+Complect);
ObjectDelete("VLine2 Complect¹"+Complect);
ObjectDelete("VLine3 Complect¹"+Complect);
ObjectDelete("VLine4 Complect¹"+Complect);
ObjectDelete("VLine5 Complect¹"+Complect);
ObjectDelete("HLine1 Complect¹"+Complect);
ObjectDelete("HLine2 Complect¹"+Complect);
ObjectDelete("HLine3 Complect¹"+Complect);
ObjectDelete("HLine4 Complect¹"+Complect);
ObjectDelete("HLine5 Complect¹"+Complect);
ObjectDelete("MainCrossLine1 Complect¹"+Complect);
ObjectDelete("MainCrossLine2 Complect¹"+Complect);
ObjectDelete("SubMainCross1Line1 Complect¹"+Complect);
ObjectDelete("SubMainCross1Line2 Complect¹"+Complect);
ObjectDelete("SubMainCross2Line1 Complect¹"+Complect);
ObjectDelete("SubMainCross2Line2 Complect¹"+Complect);
ObjectDelete("Diag1Line1 Complect¹"+Complect);
ObjectDelete("Diag1Line2 Complect¹"+Complect);
ObjectDelete("Diag1Line3 Complect¹"+Complect);
ObjectDelete("Diag1Line4 Complect¹"+Complect);
ObjectDelete("Diag2Line1 Complect¹"+Complect);
ObjectDelete("Diag2Line2 Complect¹"+Complect);
ObjectDelete("Diag2Line3 Complect¹"+Complect);
ObjectDelete("Diag2Line4 Complect¹"+Complect);
ObjectDelete("FirstCrossLine1 Complect¹"+Complect);
ObjectDelete("FirstCrossLine2 Complect¹"+Complect);
ObjectDelete("LastCrossLine1 Complect¹"+Complect);
ObjectDelete("LastCrossLine2 Complect¹"+Complect);
//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator iteration function |
//+------------------------------------------------------------------+
int start()
{
int error=GetLastError();
//----
if(stopper)
{
if(prevtime == Time[0]) return(0);
if(error!=4066) prevtime = Time[0];
}
//----
int iH, iL, P, nP1, nP2, nH, nL, nPoint2, nPoint1, i, time3, time4, time5;
int pointcode;
double period, scale;
bool up;
datetime Date1, Date2;
string freeze="";
if(save) freeze=" saved";
//----
if(vlines_style<0 || vlines_style>4) vlines_style=0;
if(hlines_style<0 || hlines_style>4) hlines_style=0;
if(style1<0 || style1>4) style1=0;
if(style2<0 || style2>4) style2=0;
if(style3<0 || style3>4) style3=0;
//----
ObjectDelete("VLine1 Complect¹"+Complect);
ObjectDelete("VLine2 Complect¹"+Complect);
ObjectDelete("VLine3 Complect¹"+Complect);
ObjectDelete("VLine4 Complect¹"+Complect);
ObjectDelete("VLine5 Complect¹"+Complect);
ObjectDelete("HLine1 Complect¹"+Complect);
ObjectDelete("HLine2 Complect¹"+Complect);
ObjectDelete("HLine3 Complect¹"+Complect);
ObjectDelete("HLine4 Complect¹"+Complect);
ObjectDelete("HLine5 Complect¹"+Complect);
ObjectDelete("MainCrossLine1 Complect¹"+Complect);
ObjectDelete("MainCrossLine2 Complect¹"+Complect);
ObjectDelete("SubMainCross1Line1 Complect¹"+Complect);
ObjectDelete("SubMainCross1Line2 Complect¹"+Complect);
ObjectDelete("SubMainCross2Line1 Complect¹"+Complect);
ObjectDelete("SubMainCross2Line2 Complect¹"+Complect);
ObjectDelete("Diag1Line1 Complect¹"+Complect);
ObjectDelete("Diag1Line2 Complect¹"+Complect);
ObjectDelete("Diag1Line3 Complect¹"+Complect);
ObjectDelete("Diag1Line4 Complect¹"+Complect);
ObjectDelete("Diag2Line1 Complect¹"+Complect);
ObjectDelete("Diag2Line2 Complect¹"+Complect);
ObjectDelete("Diag2Line3 Complect¹"+Complect);
ObjectDelete("Diag2Line4 Complect¹"+Complect);
ObjectDelete("FirstCrossLine1 Complect¹"+Complect);
ObjectDelete("FirstCrossLine2 Complect¹"+Complect);
ObjectDelete("LastCrossLine1 Complect¹"+Complect);
ObjectDelete("LastCrossLine2 Complect¹"+Complect);
//----
switch (timeframe)
{
case 1:
period = OBJ_PERIOD_M1;
break;
case 5:
if(over) period = OBJ_PERIOD_M1 | OBJ_PERIOD_M5; else period = OBJ_PERIOD_M5;
break;
case 15:
if(over) period = OBJ_PERIOD_M1 | OBJ_PERIOD_M5 | OBJ_PERIOD_M15; else period = OBJ_PERIOD_M15;
break;
case 30:
if(over) period = OBJ_PERIOD_M1 | OBJ_PERIOD_M5 | OBJ_PERIOD_M15 | OBJ_PERIOD_M30; else period = OBJ_PERIOD_M30;
break;
case 60:
if(over) period = OBJ_PERIOD_M1 | OBJ_PERIOD_M5 | OBJ_PERIOD_M15 | OBJ_PERIOD_M30 | OBJ_PERIOD_H1; else period = OBJ_PERIOD_H1;
break;
case 240:
if(over) period = OBJ_PERIOD_M1 | OBJ_PERIOD_M5 | OBJ_PERIOD_M15 | OBJ_PERIOD_M30 | OBJ_PERIOD_H1 | OBJ_PERIOD_H4; else period = OBJ_PERIOD_H4;
break;
case 1440:
if(over) period = OBJ_PERIOD_M1 | OBJ_PERIOD_M5 | OBJ_PERIOD_M15 | OBJ_PERIOD_M30 | OBJ_PERIOD_H1 | OBJ_PERIOD_H4 | OBJ_PERIOD_D1; else period = OBJ_PERIOD_D1;
break;
case 10080:
if(over) period = OBJ_PERIOD_M1 | OBJ_PERIOD_M5 | OBJ_PERIOD_M15 | OBJ_PERIOD_M30 | OBJ_PERIOD_H1 | OBJ_PERIOD_H4 | OBJ_PERIOD_D1 | OBJ_PERIOD_W1; else period = OBJ_PERIOD_W1;
break;
case 43200:
period = OBJ_PERIOD_MN1;
break;
case 0:
period = NULL;
break;
case -1:
period = EMPTY;
break;
}
//----
if(handycode) pointcode=code;
else
{
switch (Complect)
{
case 0: pointcode = 139; break;
case 1: pointcode = 140; break;
case 2: pointcode = 141; break;
case 3: pointcode = 142; break;
case 4: pointcode = 143; break;
case 5: pointcode = 144; break;
case 6: pointcode = 145; break;
case 7: pointcode = 146; break;
case 8: pointcode = 147; break;
case 9: pointcode = 148; break;
case 10: pointcode = 149; break;
case 11: pointcode = 128; break;
case 12: pointcode = 129; break;
case 13: pointcode = 130; break;
case 14: pointcode = 131; break;
case 15: pointcode = 132; break;
case 16: pointcode = 133; break;
case 17: pointcode = 134; break;
case 18: pointcode = 135; break;
case 19: pointcode = 136; break;
case 20: pointcode = 137; break;
case 21: pointcode = 138; break;
default: pointcode = code;
}
}
//----
if(by_time)
{
fplace=iBarShift(NULL,0,point1_date,false);
splace=iBarShift(NULL,0,point2_date,false);
}
if(ObjectFind("Point1 Complect¹"+Complect)!=0) ObjectCreate("Point1 Complect¹"+Complect, OBJ_ARROW, 0, Time[fplace], (High[fplace]+Low[fplace])/2);
if(ObjectFind("Point2 Complect¹"+Complect)!=0) ObjectCreate("Point2 Complect¹"+Complect, OBJ_ARROW, 0, Time[splace], (High[splace]+Low[splace])/2);
//----
ObjectSet("Point1 Complect¹"+Complect,OBJPROP_ARROWCODE,pointcode);
ObjectSet("Point1 Complect¹"+Complect,OBJPROP_COLOR,point_col);
ObjectSet("Point1 Complect¹"+Complect,OBJPROP_WIDTH,point_width);
ObjectSet("Point1 Complect¹"+Complect,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Point2 Complect¹"+Complect,OBJPROP_ARROWCODE,pointcode);
ObjectSet("Point2 Complect¹"+Complect,OBJPROP_COLOR,point_col);
ObjectSet("Point2 Complect¹"+Complect,OBJPROP_WIDTH,point_width);
ObjectSet("Point2 Complect¹"+Complect,OBJPROP_TIMEFRAMES,period);
//----
Date1=ObjectGet("Point1 Complect¹"+Complect,OBJPROP_TIME1);
Date2=ObjectGet("Point2 Complect¹"+Complect,OBJPROP_TIME1);
//----
nP1=iBarShift(NULL,0,Date1,false);
nP2=iBarShift(NULL,0,Date2,false);
if(nP1>nP2)
{
P=nP1;
nP1=nP2;
nP2=P;
}
nH=iHighest(NULL,0,MODE_HIGH,nP2-nP1+1,nP1);
nL=iLowest(NULL,0,MODE_LOW,nP2-nP1+1,nP1);
if(nL>nH) up=true;
else if(nL<nH) up=false;
if(up)
{
nPoint2=nL;
nPoint1=nH;
}
else
{
nPoint2=nH;
nPoint1=nL;
}
if(nPoint2==nPoint1) return(0);
//----
time3=2*nPoint1-nPoint2;
time4=3*nPoint1-2*nPoint2;
time5=4*nPoint1-3*nPoint2;
//----
if(ObjectFind("VLine1 Complect¹"+Complect+freeze)!=0)
ObjectCreate("VLine1 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[nPoint2],Low[nPoint2]);
ObjectSet("VLine1 Complect¹"+Complect+freeze,OBJPROP_COLOR,vlines_col);
ObjectSet("VLine1 Complect¹"+Complect+freeze,OBJPROP_STYLE,vlines_style);
ObjectSet("VLine1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,vlines_width);
ObjectSet("VLine1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("VLine1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
if(ObjectFind("VLine2 Complect¹"+Complect+freeze)!=0)
ObjectCreate("VLine2 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[nPoint1],Low[nPoint1]);
ObjectSet("VLine2 Complect¹"+Complect+freeze,OBJPROP_COLOR,vlines_col);
ObjectSet("VLine2 Complect¹"+Complect+freeze,OBJPROP_STYLE,vlines_style);
ObjectSet("VLine2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,vlines_width);
ObjectSet("VLine2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("VLine2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
if(ObjectFind("VLine3 Complect¹"+Complect+freeze)!=0){
if(time3>=0) ObjectCreate("VLine3 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[time3],1.00);
else ObjectCreate("VLine3 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[0]-time3*Period()*60,1.00);}
ObjectSet("VLine3 Complect¹"+Complect+freeze,OBJPROP_COLOR,vlines_col);
ObjectSet("VLine3 Complect¹"+Complect+freeze,OBJPROP_STYLE,vlines_style);
ObjectSet("VLine3 Complect¹"+Complect+freeze,OBJPROP_WIDTH,vlines_width);
ObjectSet("VLine3 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("VLine3 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
if(ObjectFind("VLine4 Complect¹"+Complect+freeze)!=0){
if(time4>=0) ObjectCreate("VLine4 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[time4],1.00);
else ObjectCreate("VLine4 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[0]-time4*Period()*60,1.00);}
ObjectSet("VLine4 Complect¹"+Complect+freeze,OBJPROP_COLOR,vlines_col);
ObjectSet("VLine4 Complect¹"+Complect+freeze,OBJPROP_STYLE,vlines_style);
ObjectSet("VLine4 Complect¹"+Complect+freeze,OBJPROP_WIDTH,vlines_width);
ObjectSet("VLine4 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("VLine4 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
if(ObjectFind("VLine5 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("VLine5 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[time5],1.00);
else ObjectCreate("VLine5 Complect¹"+Complect+freeze,OBJ_VLINE,0,Time[0]-time5*Period()*60,1.00);}
ObjectSet("VLine5 Complect¹"+Complect+freeze,OBJPROP_COLOR,vlines_col);
ObjectSet("VLine5 Complect¹"+Complect+freeze,OBJPROP_STYLE,vlines_style);
ObjectSet("VLine5 Complect¹"+Complect+freeze,OBJPROP_WIDTH,vlines_width);
ObjectSet("VLine5 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("VLine5 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
if(up)
{
if(ObjectFind("HLine1 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine1 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],Low[nPoint2]);
//----
if(ObjectFind("HLine2 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine2 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],Low[nPoint2]+(High[nPoint1]-Low[nPoint2])/4);
//----
if(ObjectFind("HLine3 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine3 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],(High[nPoint1]+Low[nPoint2])/2);
//----
if(ObjectFind("HLine4 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine4 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],High[nPoint1]-(High[nPoint1]-Low[nPoint2])/4);
//----
if(ObjectFind("HLine5 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine5 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint1],High[nPoint1]);
//----
if(ObjectFind("MainCrossLine1 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("MainCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[time5],High[nPoint1]);
else ObjectCreate("MainCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[0]-time5*Period()*60,High[nPoint1]);}
//----
if(ObjectFind("MainCrossLine2 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("MainCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[time5],Low[nPoint2]);
else ObjectCreate("MainCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[0]-time5*Period()*60,Low[nPoint2]);}
//----
if(ObjectFind("SubMainCross1Line1 Complect¹"+Complect+freeze)!=0){
if(time3>=0) ObjectCreate("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[time3],High[nPoint1]);
else ObjectCreate("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[0]-time3*Period()*60,High[nPoint1]);}
//----
if(ObjectFind("SubMainCross1Line2 Complect¹"+Complect+freeze)!=0){
if(time3>=0) ObjectCreate("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[time3],Low[nPoint2]);
else ObjectCreate("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[0]-time3*Period()*60,Low[nPoint2]);}
//----
if(ObjectFind("SubMainCross2Line1 Complect¹"+Complect+freeze)!=0){
ObjectCreate("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time3>=0) ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time3]);
else ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time3*Period()*60);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_PRICE1,Low[nPoint2]);
if(time5>=0) ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_PRICE2,High[nPoint1]);}
//----
if(ObjectFind("SubMainCross2Line2 Complect¹"+Complect+freeze)!=0){
ObjectCreate("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time3>=0) ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time3]);
else ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time3*Period()*60);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_PRICE1,High[nPoint1]);
if(time5>=0) ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_PRICE2,Low[nPoint2]);}
//----
if(ObjectFind("Diag1Line1 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[time5],Low[nPoint2]+(High[nPoint1]-Low[nPoint2])/4);
else ObjectCreate("Diag1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[0]-time5*Period()*60,Low[nPoint2]+(High[nPoint1]-Low[nPoint2])/4);}
//----
if(ObjectFind("Diag1Line2 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[time5],(Low[nPoint2]+High[nPoint1])/2);
else ObjectCreate("Diag1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[0]-time5*Period()*60,(Low[nPoint2]+High[nPoint1])/2);}
//----
if(ObjectFind("Diag1Line3 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[time5],(Low[nPoint2]+High[nPoint1])/2);
else ObjectCreate("Diag1Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[0]-time5*Period()*60,(Low[nPoint2]+High[nPoint1])/2);}
//----
if(ObjectFind("Diag1Line4 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[time5],High[nPoint1]-(High[nPoint1]-Low[nPoint2])/4);
else ObjectCreate("Diag1Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[0]-time5*Period()*60,High[nPoint1]-(High[nPoint1]-Low[nPoint2])/4);}
//----
if(ObjectFind("Diag2Line1 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2]+(High[nPoint1]-Low[nPoint2])/4,Time[time5],Low[nPoint2]);
else ObjectCreate("Diag2Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2]+(High[nPoint1]-Low[nPoint2])/4,Time[0]-time5*Period()*60,Low[nPoint2]);}
//----
if(ObjectFind("Diag2Line2 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(Low[nPoint2]+High[nPoint1])/2,Time[time5],Low[nPoint2]);
else ObjectCreate("Diag2Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(Low[nPoint2]+High[nPoint1])/2,Time[0]-time5*Period()*60,Low[nPoint2]);}
//----
if(ObjectFind("Diag2Line3 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(Low[nPoint2]+High[nPoint1])/2,Time[time5],High[nPoint1]);
else ObjectCreate("Diag2Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(Low[nPoint2]+High[nPoint1])/2,Time[0]-time5*Period()*60,High[nPoint1]);}
//----
if(ObjectFind("Diag2Line4 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1]-(High[nPoint1]-Low[nPoint2])/4,Time[time5],High[nPoint1]);
else ObjectCreate("Diag2Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1]-(High[nPoint1]-Low[nPoint2])/4,Time[0]-time5*Period()*60,High[nPoint1]);}
//----
if(ObjectFind("FirstCrossLine1 Complect¹"+Complect+freeze)!=0)
ObjectCreate("FirstCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint2],Time[nPoint1],High[nPoint1]);
//----
if(ObjectFind("FirstCrossLine2 Complect¹"+Complect+freeze)!=0)
ObjectCreate("FirstCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint1],Time[nPoint1],Low[nPoint2]);
//----
if(ObjectFind("LastCrossLine1 Complect¹"+Complect+freeze)!=0){
ObjectCreate("LastCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time4>=0) ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time4]);
else ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time4*Period()*60);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_PRICE1,Low[nPoint2]);
if(time5>=0) ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_PRICE2,High[nPoint1]);}
//----
if(ObjectFind("LastCrossLine2 Complect¹"+Complect+freeze)!=0){
ObjectCreate("LastCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time4>=0) ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time4]);
else ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time4*Period()*60);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_PRICE1,High[nPoint1]);
if(time5>=0) ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_PRICE2,Low[nPoint2]);}
}
//----
else
{
if(ObjectFind("HLine1 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine1 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],High[nPoint2]);
//----
if(ObjectFind("HLine2 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine2 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],High[nPoint2]-(High[nPoint2]-Low[nPoint1])/4);
//----
if(ObjectFind("HLine3 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine3 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],(High[nPoint2]+Low[nPoint1])/2);
//----
if(ObjectFind("HLine4 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine4 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint2],Low[nPoint1]+(High[nPoint2]-Low[nPoint1])/4);
//----
if(ObjectFind("HLine5 Complect¹"+Complect+freeze)!=0)
ObjectCreate("HLine5 Complect¹"+Complect+freeze,OBJ_HLINE,0,Time[nPoint1],Low[nPoint1]);
//----
if(ObjectFind("MainCrossLine1 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("MainCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[time5],Low[nPoint1]);
else ObjectCreate("MainCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[0]-time5*Period()*60,Low[nPoint1]);}
//----
if(ObjectFind("MainCrossLine2 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("MainCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[time5],High[nPoint2]);
else ObjectCreate("MainCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[0]-time5*Period()*60,High[nPoint2]);}
//----
if(ObjectFind("SubMainCross1Line1 Complect¹"+Complect+freeze)!=0){
if(time3>=0) ObjectCreate("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[time3],Low[nPoint1]);
else ObjectCreate("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[0]-time3*Period()*60,Low[nPoint1]);}
//----
if(ObjectFind("SubMainCross1Line2 Complect¹"+Complect+freeze)!=0){
if(time3>=0) ObjectCreate("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[time3],High[nPoint2]);
else ObjectCreate("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[0]-time3*Period()*60,High[nPoint2]);}
//----
if(ObjectFind("SubMainCross2Line1 Complect¹"+Complect+freeze)!=0){
ObjectCreate("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time3>=0) ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time3]);
else ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time3*Period()*60);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_PRICE1,High[nPoint2]);
if(time5>=0) ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_PRICE2,Low[nPoint1]);}
//----
if(ObjectFind("SubMainCross2Line2 Complect¹"+Complect+freeze)!=0){
ObjectCreate("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time3>=0) ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time3]);
else ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time3*Period()*60);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_PRICE1,Low[nPoint1]);
if(time5>=0) ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_PRICE2,High[nPoint2]);}
//----
if(ObjectFind("Diag1Line1 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[time5],High[nPoint2]-(High[nPoint2]-Low[nPoint1])/4);
else ObjectCreate("Diag1Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[0]-time5*Period()*60,High[nPoint2]-(High[nPoint2]-Low[nPoint1])/4);}
//----
if(ObjectFind("Diag1Line2 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[time5],(High[nPoint2]+Low[nPoint1])/2);
else ObjectCreate("Diag1Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[0]-time5*Period()*60,(High[nPoint2]+Low[nPoint1])/2);}
//----
if(ObjectFind("Diag1Line3 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[time5],(High[nPoint2]+Low[nPoint1])/2);
else ObjectCreate("Diag1Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[0]-time5*Period()*60,(High[nPoint2]+Low[nPoint1])/2);}
//----
if(ObjectFind("Diag1Line4 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag1Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[time5],Low[nPoint1]+(High[nPoint2]-Low[nPoint1])/4);
else ObjectCreate("Diag1Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[0]-time5*Period()*60,Low[nPoint1]+(High[nPoint2]-Low[nPoint1])/4);}
//----
if(ObjectFind("Diag2Line1 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2]-(High[nPoint2]-Low[nPoint1])/4,Time[time5],High[nPoint2]);
else ObjectCreate("Diag2Line1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2]-(High[nPoint2]-Low[nPoint1])/4,Time[0]-time5*Period()*60,High[nPoint2]);}
//----
if(ObjectFind("Diag2Line2 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(High[nPoint2]+Low[nPoint1])/2,Time[time5],High[nPoint2]);
else ObjectCreate("Diag2Line2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(High[nPoint2]+Low[nPoint1])/2,Time[0]-time5*Period()*60,High[nPoint2]);}
//----
if(ObjectFind("Diag2Line3 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(High[nPoint2]+Low[nPoint1])/2,Time[time5],Low[nPoint1]);
else ObjectCreate("Diag2Line3 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],(High[nPoint2]+Low[nPoint1])/2,Time[0]-time5*Period()*60,Low[nPoint1]);}
//----
if(ObjectFind("Diag2Line4 Complect¹"+Complect+freeze)!=0){
if(time5>=0) ObjectCreate("Diag2Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1]+(High[nPoint2]-Low[nPoint1])/4,Time[time5],Low[nPoint1]);
else ObjectCreate("Diag2Line4 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1]+(High[nPoint2]-Low[nPoint1])/4,Time[0]-time5*Period()*60,Low[nPoint1]);}
//----
if(ObjectFind("FirstCrossLine1 Complect¹"+Complect+freeze)!=0)
ObjectCreate("FirstCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],High[nPoint2],Time[nPoint1],Low[nPoint1]);
//----
if(ObjectFind("FirstCrossLine2 Complect¹"+Complect+freeze)!=0)
ObjectCreate("FirstCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,Time[nPoint2],Low[nPoint1],Time[nPoint1],High[nPoint2]);
//----
if(ObjectFind("LastCrossLine1 Complect¹"+Complect+freeze)!=0){
ObjectCreate("LastCrossLine1 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time4>=0) ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time4]);
else ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time4*Period()*60);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_PRICE1,High[nPoint2]);
if(time5>=0) ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_PRICE2,Low[nPoint1]);}
//----
if(ObjectFind("LastCrossLine2 Complect¹"+Complect+freeze)!=0){
ObjectCreate("LastCrossLine2 Complect¹"+Complect+freeze,OBJ_TREND,0,0,0,0,0);
if(time4>=0) ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[time4]);
else ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME1,Time[0]-time4*Period()*60);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_PRICE1,Low[nPoint1]);
if(time5>=0) ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[time5]);
else ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIME2,Time[0]-time5*Period()*60);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_PRICE2,High[nPoint2]);}
}
//----
ObjectSet("HLine1 Complect¹"+Complect+freeze,OBJPROP_COLOR,hlines_col);
ObjectSet("HLine1 Complect¹"+Complect+freeze,OBJPROP_STYLE,hlines_style);
ObjectSet("HLine1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,hlines_width);
ObjectSet("HLine1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("HLine1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("HLine2 Complect¹"+Complect+freeze,OBJPROP_COLOR,hlines_col);
ObjectSet("HLine2 Complect¹"+Complect+freeze,OBJPROP_STYLE,hlines_style);
ObjectSet("HLine2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,hlines_width);
ObjectSet("HLine2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("HLine2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("HLine3 Complect¹"+Complect+freeze,OBJPROP_COLOR,hlines_col);
ObjectSet("HLine3 Complect¹"+Complect+freeze,OBJPROP_STYLE,hlines_style);
ObjectSet("HLine3 Complect¹"+Complect+freeze,OBJPROP_WIDTH,hlines_width);
ObjectSet("HLine3 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("HLine3 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("HLine4 Complect¹"+Complect+freeze,OBJPROP_COLOR,hlines_col);
ObjectSet("HLine4 Complect¹"+Complect+freeze,OBJPROP_STYLE,hlines_style);
ObjectSet("HLine4 Complect¹"+Complect+freeze,OBJPROP_WIDTH,hlines_width);
ObjectSet("HLine4 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("HLine4 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("HLine5 Complect¹"+Complect+freeze,OBJPROP_COLOR,hlines_col);
ObjectSet("HLine5 Complect¹"+Complect+freeze,OBJPROP_STYLE,hlines_style);
ObjectSet("HLine5 Complect¹"+Complect+freeze,OBJPROP_WIDTH,hlines_width);
ObjectSet("HLine5 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("HLine5 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("MainCrossLine1 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour1);
ObjectSet("MainCrossLine1 Complect¹"+Complect+freeze,OBJPROP_STYLE,style1);
ObjectSet("MainCrossLine1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width1);
ObjectSet("MainCrossLine1 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("MainCrossLine1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("MainCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("MainCrossLine2 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour1);
ObjectSet("MainCrossLine2 Complect¹"+Complect+freeze,OBJPROP_STYLE,style1);
ObjectSet("MainCrossLine2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width1);
ObjectSet("MainCrossLine2 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("MainCrossLine2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("MainCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("SubMainCross1Line1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("SubMainCross1Line2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("SubMainCross2Line1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("SubMainCross2Line2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag1Line1 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("Diag1Line1 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("Diag1Line1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("Diag1Line1 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag1Line1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag1Line1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag1Line2 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("Diag1Line2 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("Diag1Line2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("Diag1Line2 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag1Line2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag1Line2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag1Line3 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("Diag1Line3 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("Diag1Line3 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("Diag1Line3 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag1Line3 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag1Line3 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag1Line4 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("Diag1Line4 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("Diag1Line4 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("Diag1Line4 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag1Line4 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag1Line4 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag2Line1 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("Diag2Line1 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("Diag2Line1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("Diag2Line1 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag2Line1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag2Line1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag2Line2 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("Diag2Line2 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("Diag2Line2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("Diag2Line2 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag2Line2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag2Line2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag2Line3 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour2);
ObjectSet("Diag2Line3 Complect¹"+Complect+freeze,OBJPROP_STYLE,style2);
ObjectSet("Diag2Line3 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width2);
ObjectSet("Diag2Line3 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag2Line3 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag2Line3 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("Diag2Line4 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("Diag2Line4 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("Diag2Line4 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("Diag2Line4 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("Diag2Line4 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("Diag2Line4 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("FirstCrossLine1 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("FirstCrossLine1 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("FirstCrossLine1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("FirstCrossLine1 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("FirstCrossLine1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("FirstCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("FirstCrossLine2 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("FirstCrossLine2 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("FirstCrossLine2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("FirstCrossLine2 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("FirstCrossLine2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("FirstCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("LastCrossLine1 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_COLOR,colour3);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_STYLE,style3);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_WIDTH,width3);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_RAY,false);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_BACK,backgr);
ObjectSet("LastCrossLine2 Complect¹"+Complect+freeze,OBJPROP_TIMEFRAMES,period);
//----
return(0);
}
//+------------------------------------------------------------------+
Comments