- initialize
- login
- shutdown
- version
- last_error
- account_info
- terminal_info
- symbols_total
- symbols_get
- symbol_info
- symbol_info_tick
- symbol_select
- market_book_add
- market_book_get
- market_book_release
- copy_rates_from
- copy_rates_from_pos
- copy_rates_range
- copy_ticks_from
- copy_ticks_range
- orders_total
- orders_get
- order_calc_margin
- order_calc_profit
- order_check
- order_send
- positions_total
- positions_get
- history_orders_total
- history_orders_get
- history_deals_total
- history_deals_get
order_calc_profit
Belirtilen alım-satım işlemi için hesap para birimi cinsinden kârı geri döndürür.
order_calc_profit(
|
Parametreler
action
[in] Emir tipi iki ORDER_TYPE sayım değerinden biri olabilir: ORDER_TYPE_BUY veya ORDER_TYPE_SELL. Gerekli adsız parametre.
symbol
[in] Finansal enstrüman adı. Gerekli adsız parametre.
volume
[in] İşlem hacmi. Gerekli adsız parametre.
price_open
[in] Açılış fiyatı. Gerekli adsız parametre.
price_close
[in] Kapanış fiyatı. Gerekli adsız parametre.
Geri dönüş değeri
Başarılı olursa gerçek değer, aksi takdirde None geri döner. Hataya ilişkin bilgiler last_error() kullanılarak elde edilebilir.
Not
Fonksiyon, mevcut hesapta ve mevcut alım-satım ortamında bir alım-satım işleminin sonucunun hesaplanmasına olanak sağlar. Fonksiyon, OrderCalcProfit'e benzerdir.
Örnek:
import MetaTrader5 as mt5
|
Ayrıca bakınız