Questions from Beginners MQL5 MT5 MetaTrader 5 - page 137

 
Can you tell me how to simply sell an order you have already bought? What does Exchange Execution mean?
 
rachel21:
Can you tell me how to simply sell an order you have already bought? What does Exchange Execution mean?

https://www.metatrader5.com/ru/terminal/help/trading/performing_deals#position_manage

Close a trade.

 
I can't find how to find out the price of the last tick. Not Bid, not Ask, but the real price. (Can you give me a hint?))
 
agvozdezkiy:
I can't find how to find out the price of the last tick. Not Bid, not Ask, but the real price. (Can you tell me please?))
Bid and Ask or Last is the price of the last tick.
 

Hello!

As for the equipment, as I understand, I need devices that support installation of MT4/MT5 terminals, and with standard functionality, those devices with android, for example, are only suitable for the physical presence in the online and receive signals on the terminals installed on them, and the configuration of accounts and signal selection should be carried out from a stationary, for example.

 
Serg_72:

Hello!

As for the equipment, as I understand, I need devices that support installation of MT4/MT5 terminals, and with standard functionality, those devices with android, for example, are only suitable for the physical presence in the online and receive signals on the terminals installed on them, and the configuration of accounts and signal selection should be carried out from a stationary, for example.

The most useful option is to have a VPS (virtual private server) and install the signals on MT4/MT5 there.
 

Teach how to use CChart to change the timeframe in the charts.

Would it be more convenient to use something else?

The task is this: I need a hotkey script that will change the timeframe to a preset one in the script in all open charts.

Документация по MQL5: Операции с графиками / ChartOpen
Документация по MQL5: Операции с графиками / ChartOpen
  • www.mql5.com
Операции с графиками / ChartOpen - Документация по MQL5
 
amikkima:

Teach how to use CChart to change the timeframe in the charts.

Would it be more convenient to use something else?

The task is this, we need a hotkey script that will change the timeframe to a preset one in the script in all open charts.

The easiest thing to do:

   for(long i=ChartNext(0);i>0;i=ChartNext(i))
    {
     ChartSetSymbolPeriod(i, ChartSymbol(i), NewTimeFrame);
     ChartRedraw(i);
    } // for(Charts)

It's tested.

It works.

 

Thank you, I see why it didn't work myself.

ChartRedraw(i);
 

Another question, how can the script be placed on the number part of the keypad instead of the Alt+[] key combination?

Or pass a command to the script when a key is pressed?

I found the OnChartEvent function that allows me to track key presses...

Next I had to make an EA, because the script works out and closes.

Reason: