거래 로봇을 무료로 다운로드 하는 법을 시청해보세요
당사를 Telegram에서 찾아주십시오!
당사 팬 페이지에 가입하십시오
스크립트가 흥미로우신가요?
그렇다면 링크 to it -
하셔서 다른 이들이 평가할 수 있도록 해보세요
스크립트가 마음에 드시나요? MetaTrader 5 터미널에서 시도해보십시오
라이브러리

Functions to simplify work with orders - MetaTrader 5용 라이브러리

조회수:
6743
평가:
(48)
게시됨:
2010.08.25 09:48
업데이트됨:
2016.11.22 07:32
\MQL5\Include\
k_orders.mqh (6.91 KB) 조회
\MQL5\Scripts\
MQL5 프리랜스 이 코드를 기반으로 한 로봇이나 지표가 필요하신가요? 프리랜스로 주문하세요 프리랜스로 이동

This is a class that will allow to open, close and modify your position by placing orders with really simple commands and configuration: Buy(), Sell(), Close(), Modify().

It has never been so easy! :) 

Sample:

#include <K_Orders.mqh>

input int TP = 70;
input int SL = 20;
input double Lots=0.2;

Order order;
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//--- set default values
   order.SetLots(Lots);
   order.SetMagic(123);
   order.SetSL_inPoints(SL);
   order.SetTP_inPoints(TP);
   order.SetComment("MyExpert");

   order.Buy();   // Buy
   order.Sell();  // Close buy order
   order.Buy();   // Buy again

                  //   order.SetSL_inPrice(1.26685); // Specify StopLoss value in "Price"
   order.SetTP_inPoints(30);     // Specify TakeProfit value in "Points"
   order.Modify();               // Do the modification

   order.Close_Volume(0.1);      //Close half from 0.2 volume order
   order.Close();                //Close the rest
  }
MACD Histogram, multi-timeframe, multi-color [v03] MACD Histogram, multi-timeframe, multi-color [v03]

MACD indicator with histogram, can be applied any timeframe (higher or lower than the current chart's timeframe).

MACD Histogram, multi-color [v04] MACD Histogram, multi-color [v04]

MACD indicator with MACD line, Signal line and multi-color histogram.

RSI multi-timeframe [v03] RSI multi-timeframe [v03]

RSI indicator, can be applied to any timeframe (higher or lower than the current chart's timeframe).

Stochastic multi-timeframe [v04] Stochastic multi-timeframe [v04]

Stochastic indicator, can be applied to any timeframe (higher or lower than the current chart's timeframe).