Saving and extracting things

 

Hi guys,

I was reading the forum and manuals but nothing... This is my code:

for (int Count = 0; Count < OrdersHistoryTotal(); Count ++)
{
OrderSelect(Count, SELECT_BY_POS, MODE_HISTORY);
if (OrderSymbol() == Symbol())
{
double price_ini = OrderOpenPrice();
double time_ini = OrderOpenTime();
double time_fin = OrderCloseTime();
}

}


Now i can do a print for example and i can see my data, but i want to save it in my excel. How can i save it easily?

Thanks!

 
Use the file functions : https://docs.mql4.com/files
 
RaptorUK:
Use the file functions : https://docs.mql4.com/files

Raptor, can i save the data in Arrays?


For example, an Array of 3 dimensions with time_ini, time_fin, price_ini?? I need to save it together but i don't know how to do this!
 
You can write out to a CSV file, time_ini, time_fin, price_ini, try searching you will find lots of code examples.
 
RaptorUK:
You can write out to a CSV file, time_ini, time_fin, price_ini, try searching you will find lots of code examples.

Thanks raptor, you're awesome :)