[ARCHIVE] Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 3. - page 541

 
TEXX:

I have these questions:

- is it possible to organise order data into an array (ticket, opening price, lot, SL, TP)?

- How convenient is it to work with orders through an array?

Thanks to everyone who will answer!


It is not convenient to cover with a motorbike, so your question has a similar answer.

If you just need to work with orders - just work with them.

If you need data on the parameters of orders (the order candidates), then the array is handy. It is easier to use a set of one-dimensional arrays of variable size, imho.

Don't skimp on the time of opening, the array will come in handy :).

If you want to use ticket number as an index in arrays, you don't need arrays. Just work with orders - everything else has already been implemented for you with metaquotes.

 
try_except:
Professionals, a word of advice. In Delphi there is such a concept as IncHour, etc. The task is to add any period of time to any date variable and not to encounter an error. For example, to the date of position opening + 9 hours 30 minutes, and then check if the time has passed. Is there something like that in mql4?
Add the number of seconds 9*60*60+30*60 to the date of opening, then compare the time with the current time.
 
TEXX:

I have these questions:

- is it possible to organise order data into an array (ticket, opening price, lot, SL, TP)?

- How convenient is it to work with orders through an array?

Thanks to everyone who will answer!

Possibly. That's handy. I do it myself.
 
TEXX:

I have these questions:

- is it possible to organise order data into an array (ticket, opening price, lot, SL, TP)?

- How convenient is it to work with orders through an array?

Thanks to everyone who will answer!


It is possible to organise, but why?

If we are to sort out the orders by a trait and then analyze them in the descending order, we cannot do without the array.

And to "just" put the orders into an array, would only complicate the code with useless constructs (to control constantly the relevance of the arrays; to store all the information about the orders, if we don't need all of it during processing).

 
Zdrastvujte podskazite pozalsta themplatten jest li takaja papka i kak jejo najti.? templaten to jest, ili eto odno i toze?
 

Hello! Compiling, gives an error. Stuck can't figure out what's wrong.

 
orb:

Hello! Compiling, gives an error. Stuck can't figure out what's wrong.

you have to declare the array first and then use it, not all mush
 
ilunga:
first declare the array and then use it, not all mush
Thank you!
 
ilunga:
you have to declare the array first and then use it, not all mush
If the size of the array is not known, will the size become clear after reading the file?
 
orb:
If you don't know the size of the array, will the size become clear after reading the file?
either spin through ArrayResize , or create an array with a margin and store the actual size next to it
Reason: