Position open Time

 

Hello,


does anyone have an idea 

i want to selct positions and therefore i also check the Position_open_time


with followng code

datetime position_time = PositionGetInteger(POSITION_TIME);


when i compile i get following message

possible loss of data due to type conversion


and i dont understand why.

even if i change datetime to int ive got the same message


amando

 
amando i dont understand why. even if

Perhaps you should read the manual. The function returns a long. Cast it to the proper type.

          Trade Functions / PositionGetInteger - Reference on algorithmic/automated trading language for MetaTrader 5
Reason: