Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 6. - page 41

 
Desead :
Comrades advise how to make it so that when you run the EA opens a window of a license agreement as in the installation of any third-party software with a choice of buttons agree or not. Maybe in the standard library type user32.dll is something like this?
https://docs.mql4.com/ru/common/MessageBox
 
This message box can't hold a lot of text, just a couple of lines. I need a couple of pages of text with scrolling to the right and buttons at the bottom, or at the very least no buttons.
 
Desead :
This message box doesn't hold a lot of text, just a couple of lines. I need a couple of pages of text with scrolling to the right and buttons at the bottom, or at the very least no buttons.

I used to put 40 lines in there. There is no limit. Can only go beyond the screen.
 
Desead :
Comrades advise how to make it so that when you run the EA opens a window of a license agreement as in the installation of any third-party software with a choice of buttons agree or not. Maybe the standard libraries like user32.dll is something like that?

I used Delphi to manage the trading process. Very easy, no more difficult than MQL, I think on 1C...
 

Gurus, can you tell me what's wrong? I need the EA to open a trade on a certain day of the week.

den_nedeli = (DayOfWeek()==1);

if  (iOpen(Symbol(),Period(),0)==true && den_nedeli) 
          {                                          
          Opn_B=true;                         
          }
 
Forexman77 :

Gurus, can you tell me what's wrong? I want my Expert Advisor to open trades on a certain day of the week.

den_nedeli = 5; // i.e. on Friday, or early Thursday for example, then den_nedeli = 4,

bool Opn_B = false;

if ( DayOfWeek() == den_nedeli )

{

Opn_B = true;

}

 

The question is, is it possible to make a window indicator with some information drawn in a chart (for example, MACD in the window and arrows at crossing of lines in the chart).

and also, preferably arrows should not be objects, but an indicator.

P.S. I am solving the problem with the help of a template, but it is not very convenient, because I have to constantly change the parameters, I am testing

 
Boeing747 :

den_nedeli = 5; // i.e. on Friday, you can also early on Thursday for example, then den_nedeli = 4,

bool Opn_B = false;

if ( DayOfWeek() == den_nedely )

{

Opn_B = true;

}

I did this

if ( DayOfWeek() == 1)
      {
      Opn_B = true;
      }

bool Opn_B = false; in start is already there. Started to open a trade. Now I need the trade to close at the close. It may be at the last minutes of the day. How to make it happen?

Something like this

if (iClose(Symbol(),Period(),1)==true)
      {                                           
      Cls_B=true;                 
      }
does not work because time has passed and you need to close at the last minute of the day. What is your advice?
 
Forexman77 :

I have done the following

bool Opn_B = false; in start is already there. Started to open a trade. Now I need the trade to close at the close. It may be at the last minutes of the day. How to make it happen?

Something like this

Doesn't work because time has passed and you need to close at the last minute of the day. What is your advice?

You can try it this way:

In the Expert Advisor settings, specify the closing time in this format and without spaces in the input line, for simplicity the server time is selected.

//-----

extern string TimeClose = "23:3"; // the closing time means 23:03, we don't write zero,

if ( ( ""+Hour()+": "+Minute()+"" == TimeClose )

{

Cls_B = true;

}

here is a more reliable way in case the Expert Advisor will not be able to close the position within one minute, as in the first variant

extern int TimeClose= 2303; // the closing time means 23:03

if ( 100 * Hour() + Minute() >= TimeClose )

{

CL_B = true;

}

 
Boeing747 :

You can try it this way:

In the EA settings, specify the closing time on the input line in this format and without spaces, for simplicity the time is chosen server time.

//-----

extern string TimeClose = "23:3"; //the closing time means 23:03, we don't write zero,

if ( ( ""+Hour()+": "+Minute()+"" == TimeClose )

{

Cls_B = true;

}

Thank you so much!