question about MT4 platform charts

 
let's say I have opened many charts of the same symbol on the same MT4 platform, is there a way to show a trade level's entry and its TP and SL on one chart only, then open a new trade from another chart and show its entry level and TP and SL without interfere with the previous trade levels ???
 
Ynal Al Khalil:
let's say I have opened many charts of the same symbol on the same MT4 platform, is there a way to show a trade level's entry and its TP and SL on one chart only, then open a new trade from another chart and show its entry level and TP and SL without interfere with the previous trade levels ???

Each trade is independent on mt4 

(but if one causes a margin issue it affects all of them)
 
Ynal Al Khalil:
let's say I have opened many charts of the same symbol on the same MT4 platform, is there a way to show a trade level's entry and its TP and SL on one chart only, then open a new trade from another chart and show its entry level and TP and SL without interfere with the previous trade levels ???

only by creating a custom indicator that you will be able to select an open trade to show on the chart with objects on the chart.

 
Lorentzos Roussos #:

Each trade is independent on mt4 

(but if one causes a margin issue it affects all of them)

you didn't understand me ......

 
Ynal Al Khalil #:

you didn't understand me ......

As  Michael Charles Schefe alluded...

You could store the ChartID() [at the time of trade execution]:

Forum on trading, automated trading systems and testing trading strategies

how i can get the chart id of all the opened chart

honest_knave, 2016.07.25 16:32

Or more simply:

long chartID=ChartFirst();
while(chartID >= 0)
  {
   Print(chartID);
   chartID = ChartNext(chartID);
  }

and then use ObjectCreate() to draw trade levels to each specific ChartID():

bool  ObjectCreate(
   long          chart_id,      // chart ID
   string        object_name,   // object name
   ENUM_OBJECT   object_type,   // object type
   int           sub_window,    // window index
   datetime      time1,         // time of the first anchor point
   double        price1,        // price of the first anchor point
   ...
   datetime      timeN=0,       // time of the N-th anchor point
   double        priceN=0       // price of the N-th anchor point
   );

ObjectCreate - Object Functions - MQL4 Reference

ObjectCreate - Object Functions - MQL4 Reference
ObjectCreate - Object Functions - MQL4 Reference
  • docs.mql4.com
ObjectCreate - Object Functions - MQL4 Reference
 
Ryan L Johnson #:

As  Michael Charles Schefe alluded...

You could store the ChartID() [at the time of trade execution]:

and then use ObjectCreate() to draw trade levels to each specific ChartID():

ObjectCreate - Object Functions - MQL4 Reference

can you give me a complete code ??

 
Ynal Al Khalil #:

can you give me a complete code ??

No. Sorry. I used MT4 for years before completely switching to MT5. I actually coded custom object trade levels some time ago for MT5 [without ChartID()].

If you're willing to take all of the puzzle pieces to the MQL5 Freelance service, just shoot me a Message and I'll reply with the mq5 file. Then you can hire an MQL4 coder to convert it and add ChartID().

(I don't post mq5 files in the MQL4 subforum).