New Developer - Please give me some insights

 

Hello,

I'm a developer (not MQL) and I need to implement a simple Algorithm for a friend.

The algorithm needs to create an order, constantly check if the order is closed by stop loss. If is stopped by stop loss I need to create a new pending sale. The user must manually close the order when stop loss is never reached.

I already created a script that creates a new order, and is constantly checking the state of this order (using a while(true) and checking if order closed value = stop loss).

My questions are:

  • Should I create this algorithm in a script? Because I don't know if it's possible to make the user send information to the running script (to stop it).
  • If using a While(true) in a script and I never "leave" the while, does MQL stops the script automatically? I mean, can I have a script that never ends running?at
  • If I shouldn't use a script what are the other alternatives?


Thanks (and sorry my English :D)

 
use an EA
 
qjol:
use an EA

By EA you mean Expert advisor, correct?


Thanks.

 
Y
 
qjol:
Y

Thanks!!
 
you should go for E.A for your problem.
 
A lot of people have this question in mind, what exactly is PRICE ACTION.
And why is PRICE ACTION KING IN FOREX?
To answer the above question, i start off with talking about indicators.
There are tons of indicators out there, be it forex or others. They work mostly the same way.
And there are new indicators coming out every other day.
Alot of traders when they first started trading forex, they have tons on indicators on their charts. Trying different combination of which works best for them. And at the end of the day, they get confused all over as one indicator may be telling you to go long, but the other is telling you to go short.
Which will result in you making bad decisions and end up blowing your account with a frustrated mind.
Why does it happen this way? Indicators are derived from the chart movements. Some indicators react faster, some slower.
However, as they are derived from the chart movements. They are 1 step slower than the chart. Which is in fact Price Action!
Price Action leads the indicators, and when price reverses it movement from short to long (example). The indicator which you are watching is one step too late. And by the time the indicator confirms it is going short, Price Action has taken the market to go Long.
This happens most of time, if not all of the time.
Therefore = ALL INDICATORS ARE LAGGING INDICATORS!
PRICE ACTION IS WHAT LEADS THE INDICATORS, IT IS KING IN FOREX!
By understanding Price action in forex trading, we are able to understand the ENTIRE PICTURE of the market.
WHY is the market moving up,
WHAT causes it to stop moving,
WHY is the market reversing
WHY is the market in consolidation
IT is like reading a book once you have mastered price action in forex. And the best thing is, It is not difficult!
It is even easier than you reading an indicator.
And when you mastered price action, with combination of our system. You will almost be able to pick absolutely MARVELLOUS TRADES all the time. CONFLUENCE is the King of the game. This is what equates to our high probablity trades with a high winning ratio.
To an Awesome Trading as Always,
Ezekiel Chew
 
asiforexmentor:

And when you mastered price action, with combination of our system.
Please . . no SPAM . . it isn't allowed here.
Reason: