Ordercomment mql4 Returns open time of the currently selected order. 31 16:04 #1 In this video, we will learn how to change order comments in MQL4 file. The net profit value (without swaps or commissions) for the selected order. If you mean the way the orders were placed (both market and pending) - then yes. 09. The “Comment” command in MQL4 is a useful tool for traders who want to display text on the chart. can you change trade comment when ordersend is rejected (ERR_NOT_ENOUGH_MONEY modify order comment - Symbols - Expert Advisors and Automated Trading - MQL5 MQL4 Reference Constants, Enumerations and Structures Trade Constants Order Properties. A considerable part of those events can be detected and processed using MQL4. Vedran Brkic 2017. Example: well as I said you cannot update the comments field. Standard Deviation. mql4; Share. It is thus useful to create a order counting function that EDIT: 2018-06-12. 11 14:54 #3 I think the best thing would be for the coder to include them in order comment so its easier to spot them quicker once you select to Again, only the first and third parameters are modified. It ORDER_COMMENT. Since new ticket is open, its ticket number is larger then the closed one. When sending a trade request using the OrderSend() function, some operations require the hello guys,Can you point me to the right direction on how to add code in EA to write comment on my MT4 terminal as per attached image. iStdDev. Here is my code with 2 pending orders void On OrderStopLoss. The symbol name of the currently selected order. Print info with OrderComment() Avoid editing of Comment Questions from Beginners MQL5. Post # 3; Quote; Feb 2, 2015 8:29am Feb 2 Order Accounting. Comments are not strictly necessary to run a program, but they are very useful if you are dealing with complex code. Open time of the currently selected order. Ticket number of the currently selected order. I doubt it makes sense as you'll have to do useless parsing of MQL4 has only five functions that form and send trade orders to a server: OrderSend() - market order opening and pending order placing; OrderClose() OrderComment: It returns the comment of the selected order. Right now, my code below but is getting the profit of all open orders as opposed to just the order with a specific comment. So because: Ask > Bid and Ask - Bid = Slippage, it doesn't matter which we choose as long as we know about the slippage. The MT4 must open the order (or more than one) at a specific price. Yes. Thank you in adavance. Do you have an idea what I am miss, maybe it is not as easy as I thought. Otherwise you receive different As an MQL4 coder, you should handle these situations properly as they obviously lead to the incorrect functioning of the EA. This function outputs a comment defined by a user in the top left corner of a chart. 21 07:56 #2 Yashar I am absolutly new to MQL4 coding. PraAnj PraAnj. the only way to interact with an MT4 program is to have some input fields that you can use (but then the EA resets when you do so) to monitor an object(s) and move it about on the screen or to check for a file, which is probably the best way for you, you could update a csv file with the trade number and SLTP OrderMagicNumber - Trade Functions - MQL4 Reference Order Modification List MQL4 OrderModify is updating What so special about. What is the Limit? 45280. 574. 1141. Marcos Silva 2013. Returns the number of market and pending orders. Take profit value of the currently selected order. William Roeder 2014. NEVER EVER USE THE COMMENT SECTION OF A TICKET FOR ORDER TRACKING. Order comment. Example: MQL4 OrderModify() Function. It is your ID and is not changed by the broker. I am going to share the function I have developed for this purpose! First I thought about finding the ticket number from the "OrderOpenTime()", when I realized that when "OrderClose()" is executed, a new ticket number is assigned, but the "OrderOpenTime()" is equal to the first order before the partial close! I wrote an EA in mql4. OrderOpenTime. This command is used to add annotations or descriptions to the chart, making it easier to understand what is happening at any given moment. I have a question. I just want to check if there is an open buy position or not? I tried to use OrdersTotal() but it returns buy All MQL4 trading functions on this page require a successful call to the OrderSelect function before any information may be returned. Passing Parameters When Calling Custom Indicators from MQL4 Programs. Lastly, every-tick vs something-change comes down to processing time IMO. 07 13:44 #4 Jordon_Tucker: Hey thank your for response, how Can I modify position Keep OrderComment() at Stop Unfortunately I am not able to post the code I am debugging as it is not mine and I am bound not to show it BUT I will describe it as detailed as possible. It can be any of the following values: OP_BUY - buy order, OP_SELL - sell order, OP_BUYLIMIT - buy limit pending order, Not a broker, no real trading accounts. Open price of the currently selected order. It considers same magic number and same symbol only. Function OrderSend() int OrderSend (string OrderCloseBy. Other events, though they are interesting for a trader, too, are not explicitly shown anywhere. Improve this answer. To close the cycle, we Irtron is implying that, to change colours or fonts, you need to create a text object on the chart rather than using Comment(). New comment [Deleted] 2016. Example: ordercomment() returns the string stored as a comment with the order. OrderTakeProfit. 410. Comments in mql4 are always displayed in upper left corner but I read somewhere that they can be set in other corners thry objects if we code base for comments and then call the base from object. thanks for fbj. Checkup. Track these until one disappears from the live orders, then check in order history if it was in profit or not when it closed. Copy all the folders from the archive directly to the MQL4 folder. We then indicate that the pending price must be less than the current price by modifying the price parameter: we use Ask – Not a broker, no real trading accounts. I'm new to programming mql4. What exactly should i write in source code if i want my EA to display my email id that is, "sammiawan@gmail. Otherwise, no other-way can be done to modify the comment. Example: string comment; Can we always use always OrderComment() for this purpose? MQL4 Learning; Notification of closed orders; 2649. Properly managing orders is a fundamental skill for any trader utilizing the MQL4 platform. For example: // This is a single-line MQL4 Learning; The open orders manually opened can be read? Orderselect always retrun false. Order operation type of the currently selected order. I had someone create a script to help us test this and the limit seems to be 31 characters max, including spaces. 1 2. 12 02:52 #1 The Order Comment field is also available to label orders but this to must be done at time of order placement and can not be changed. Comment of the currently selected order. Comments. Next, you should use constants Ask and Bid when sending market orders, they are updated after refreshing rates. You'd normally want to do an ObjectDelete() in deinit(), and either create the text object in init() or make sure that it doesn't already exist before potentially creating it on each call to start(). OrderDelete. Some basic concepts. OrderComment Returns the comment for the selected order. 11 20:28 #1 System modifies the comment on some positions when closed. Learn in this MQL4 OrderSelect Function article how to get the order information and how to use Stack Overflow for Teams Where developers & technologists share private knowledge with coworkers; Advertising & Talent Reach devs & technologists worldwide about your product, service or employer brand; OverflowAI GenAI features for Teams; OverflowAPI Train & fine-tune LLMs; Labs The future of collective knowledge sharing; About the company P. Is there a max length of an order comment? New comment 102. 28 04:51 Hi, Im a little bit OrderComment. 4. OrderExpiration. each order has its ticket-id and they are incrementing. 10. I get code below from ctrade, i add code about comment When closing an order partially, it seems (I'm not exactly sure whether this is what happens exactly) that the order gets closed and a different order gets opened with the remaining quantity. Technical Indicators. We mentioned above that there were no strict rules for making program algorithms. Erman Ardianto 2008. Damien Olanier 2009. OrderTicket. In this guide, you are going to learn how to use comments in MQL4. Returns close price of the currently selected order. If the Orders variable (number of orders) is equal to 0, the Comment() function with "No orders" parameter is executed. Moderator 32375. [Deleted] 2006. When you create an expert advisor, in many cases, probably the majority, you want it to trade for you. 06. We will see in this article Kajironpu san, Let me explain with your example above, and make it more generic. Restart MetaTrader 4 or refresh the list of scripts by right-clicking the Navigator subwindow of the platform and choosing Refresh . Parameters. Follow edited Dec 18, 2015 at 20:16. g. 11 22:25 #2 Returned value. Platform code. Your price is close of the previous H1 candle. The first type is a single-line comment, which is indicated by two forward slashes (//). thanks Yes and no. There are 4 strategies base on 4 indic Returns true, if an mql4 program has been commanded to stop its operation. So for every trade, I can add custom note/comment. ORDER_EXTERNAL_ID. Anyway, your computation may take time, that is why it is strongly recommended to RefreshRates() before sending the order. Order Management in MQL4. Sylvahh Sylvahh. because the text is too small. If you're talking about mql4, the following two functions are fair enough to give you what you're looking for. 02. Returns open price of the currently selected order. string OrderComment (); Returned value. We use OP_BUYLIMIT to indicate a buy limit order. Please paste the relevant part of mql5 code. The identifying (magic) number of the currently selected order. One may opt to either poll the dbPool of records in MT4/Terminal in a rather dumb manner alike a loop Welcome to mql4. Trade requests for opening and placing pending orders are formed using the function OrderSend(). You couldn't be bothered to learn mql4, therefor there is no common language for us to communicate. How to open and place buy or sell orders in MQL4 and MQL5?MQL4 and MQL5 provide a function to facilitate the execution of trade operations. Order comments are important in forex trading as they help traders to keep track of t Comment. expiration=0 [in] Order expiration time (for pending Hi guys, i can't make updating my pending orders on every price changing, moving following price until 3 sec before news relaese (yeah another news trading ea). What can be done in a . 13 3 3 bronze badges. 2 replies. 01. Understanding the Returned value. double OrderClosePrice ();. In other guides, we saw how to open new market orders and how to scan the account for open orders. If we give you comment - Order comment text. Assume 7 open orders exist (2 manual released, 5 EA released. Ray 2008. Total amount of market and pending orders. Popov; Lead Developer; Offline; From: Bulgaria; Partial close order comment; Errors, bugs, questions; Quick question on partial close; Any newbie Questions about MQL4 About trailing stop. Modification of characteristics of the previously opened or pending orders. The order must be previously selected by the OrderSelect() function. Deletes previously opened pending order. 20 19:33 #10 Tycek: Well my own ID that I Checking Order Comment in MQL4. Follow asked Aug 30, 2022 at 13:58. I will move this to the MQL4 and MT4 section. In the EA's created with FSB I found only one "Order_Comment" line, but there it works and is shown in the Kommentar-line. It is quite easy to update an order using MQL4 language. And I want that it checks the order comment in an if-sentence after that. OrderSend - 交易函数 - MQL4 Order comment text. If there are more than 31 characters, the mt4 server seems to automatically reject the entire comment. OrderMagicNumber This function outputs a comment defined by a user in the top left corner of a chart. September 15, 2014 at 11:37 pm, tablet8 said:. To modify an order, MQL4 offers the OrderModify() function. 21 06:46 #1 Looks like 31 is the length limit. There was never a way to do this in MQL4/5 trading platforms. When you place your orders, record the ticket numbers. I changed the tp and sl to 100 but it still do not work. It seems not to work and i think my comments are a bit too long (ex : Upperband Opening and Placing Orders. Apart a few details, the answer is actually quite simple, although not obvious. If there is at least Hello, how to print more than one variable to order comment with ordercomment() function. // Join us — download MetaTrader 5! Not a broker, no real trading OrderComment() returns the string stored as a comment with the order . 5104. Share. Need to loop over all tickets, your new ticket has same magic number and comment, as well as all other entry parameters. The close price of currently selected order. i saw many ea on youtube that create moving pending order until news relaese, but i can't do this on my own. Yashar Seyyedin 2024. magic - Order magic number. However, the comment of the "remaining" order changes to something like: "From #51461". To open a trade order, //Order comment. 07. There are only two choices: learn to code it, or pay someone. Trade Functions. For open orders, it is the current unrealized profit. Anthony Garot 2018. OrderCommission. It places orders just fine using OrderSend(), but the horizontal lines showing the open price, SL and TP do not show up on the chart like it does when I manually place a trade. OrdersTotal. Returns comment of the currently selected order. Here is the code I used to place the order: Remember, in MQL4 there is no possibility of program terminating an EA's operation in a security window (as distinct from scripts, see Special Functions). OrderLots. Therefore, I would just iterate over the list of open orders and would If you're starting with automated trading on the MetaTrader 4 platform using MQL4, one of the first things you'll need to learn is how to send trading orders. In MQL4 was easy, on OrderSend() I just put the Magic number in order to identify what orders are from each expert advisors (I want to use several defining order comment in mql4 source code - page 2. OrderSelect(1,SELECT_BY_POS,MODE_HISTORY) - returns order in the middle of the history, Build 482; Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes So we know for sure the ordercomment can be changed, we just are not granted the privilege to do so from our end of the equation. Function OrderModify() Trade requests for modifying of market and pending There are two types of comments in MQL4, which is the programming language used to create EAs in the MetaTrader platform. MQL4 allows you to modify market and pending orders. I want to set the Magic Number in my robots in Metatrader 5 (MQL5). A trader can see some of them directly in the symbol window, for example, market price changes or crossed indicator lines. ticket [in] Order index or order ticket depending on the second parameter. Single-line comments begin with the // pair of symbols and end with the newline character, they can be nested in other multi-line comments. 03. Partial - not entirely realistic - code sample as follows. Umut Don't use order comment to identify orders and positions, the broker might/will change it! Use the MagicNumbers for your trading. OrderClosePrice. . The CockeyedCowboy. I use them - mostly for Buy and Sell - heavily in my codes. If it OrderComment. 15 22:46 #3 LEE Chun Wing: How OrderOpenPrice. Alternatively, it can try closing previous orders if a new order is to be opened. MQL4 documentation requires to include also an OrderExpiration value in the call, even though the Order is currently not a pending order any more. William Roeder 2020. Returns expiration date of the selected pending order. Order of Check the order comment while it is still open. answered Dec 18, 2015 at 15:58. com" in the order comments and charts. Once we have successfully placed an order, we will need to gather information about the order, particularly if we want to modify it. The subject of our interest is a program written in MQL4. New comment 38. string OrderComment ();. 929 1 1 gold badge 10 10 silver badges 27 27 bronze badges. How to determine if a trade has been closed. The core-functionality was always focused on engineering a fast, reliable soft-real-time ( providing still just a best-effort scheduling alongside the stream of externally injected FxMarket-Event-Flow ), so bear with the product as-is. New comment 103. MQL4 Order Counting Function Updated 01 July 2020. Before we start a detailed presentation of the rules of writing programs, it is necessary to describe the basic concepts that characterize a program and its Here is an MQL4 example of how this is handled in the Chart Pattern Helper EA's code: // Get current market prices. user3666197. "myRobot_5", and you parse the OrderComment() in order to get timeframe value. you should use OrderComment comparison only if your EA actually writes different Order Comment in mql4. double OrderOpenPrice ();. Note: Arrays and variables of complex types can't act as input variables. expiration=0 [in] Order expiration time (for pending orders only). is there a way to customize the color/font/size of comment() function in mql4???. Petr Nosek 2019. arrow_color=clrNONE [in] Color of the opening arrow on the chart. To send 2 values within ordersend as the order Metaquotes language: OrderComment() is not able to be modified - Futures Trading - Expert Advisors and Automated Trading - MQL5 programming forum Not a good idea to use comments, brokers can change comments, including complete replacement. 08. Order comments are set at order creation with the OrderSend function. It can be any of the following values: OrderModify. In this guide, we'll break down the process step by step. 21 10:16 #1 marktheplant: Am starting to experiment with EAs and custom indicators and would like to know if there is a fast way to 'comment-out' (//) in one go code Order Comment blank after order closed 4 replies. Then depending on what price you are following on the chart, you Hello all, i am wondering if there is a way to get multiple lines of text using comment(). The order must be previously selected by the OrderSelect () function. Last part of the comment may be changed by server. What exactly are comments? Metaquotes language: OrderComment() is not able to be modified - Expert Advisors and Automated Trading - MQL5 programming forum 2013. OrderComment. Check the documentation and the IDE tooltip, which helps one remind the order of the function call parameters. May be used Need a EA written Edit in the meta MQL4 and SeriesInfoIngteger. 04. The process is very similar to using the OrderClose() function. Close time for the currently selected order. Hi I tried a lot on this code but it didn’t work, I even copied it from your site but it didn’t work, I don’t know what’s wrong with me ! I test it on these brokers: hotforex, exness, fibogroup, all are with 5 decimals. – user3666197. Returns amount of lots of the selected order. All calculations and other actions performed due to the execution of an application program can be divided into two groups by the location of their execution: those executed in the user's PC and those executed on the server side. S. I noticed, if i enter big comments, than it became empty/blank?. It can be any of the following values: Returned value. btw, trade filtering by ticketnumber is imho dangerous because brokers may change that number after a partial closure, OrderComment - 交易函数 - MQL4 OrderComment. Print ("Order comment: "+ OrderComment ()); } } I have some questions: If you don't learn MQL4/5, there is no common language for us to communicate. anuj71 2024. At the same time, the overwhelming majority of algorithms imply making one's trading decisions according to the current status of the orders available. The newline is "\n" as a string so you might say. Order identifier in an external trading system (on the Exchange) string . Returns stop loss value of the currently selected order. Order of comment changes if: OrderExpiration. bool OrderCloseBy ( int ticket, // ticket to close int opposite, // opposite ticket color arrow_color // color Why did you post your MT4 question in the Root / MT5 General section instead of the MQL4 section, (bottom of the Root page?) General rules and best pratices of the Forum. Forex Trader 2007. Can somebody give me example how to code base and then how to call it from object? Let's say this is the comment Comment("Previous High : ",High[1],", I do not know why you want to change the magicnumber -> Can you tell us, maybe there is another way to achieve what you are looking for. May be used as user defined identifier. Returns take profit value of the currently selected order. So, what I want to return is the profit for the order that the order comment is "Testing". Returned value. It's quite simple. So the best thing to do is probably to ask them. I want it to display my contact information in order comment. 3805. datetime OrderExpiration ();. eevviill: Oh gush. You can also use Control-D followed by 'search' tab to search editors help it helps me. double OrderStopLoss ();. 114211. Operation type for the OrderSend() function. Stop loss value of the currently selected order. it is also possible that a pending order is opened after a market order (first you put a limit order, then market, then limit is executed). the problem is with ordersend part, it doesn’t execute this And seems mql4 only processes one function at a time. If order close time is not 0, then the order selected and has been closed and retrieved from the account history. Closes an opened order by another opposite opened order. MQL4 provides a suite of functions to handle, modify, and track orders. if you're just going to find the trades opened by your EA, Magic Number comparison is the way to go. Improve this question. 14 12:31 #10 I just see your posting - thanks a lot for the tip! Regards, Many events take place during trading. Good afternoon, I am trying to change the magicnumber or the comment for open trades, in order to apply a different management to them in the futur I have read MQL4 book and function reference, but i can't find the solution. 13 19:02 Hello, in my EA i use tags to manage orders. Comments are shown under the Trade tab in the Terminal window. History Database Properties; Order Properties; Signal Properties; Order Properties. int OrdersTotal ();. New comment 391. 25 21:29 #2 Jack Thomas: YOU DON'T. I want to be more creative in this part. Sad, but true. Such kind of comments cannot be nested. yas 2023. 6 Reply by Popov 2017-04-06 11:04:24. It is useful to discover how many orders our EA has open and what type these open orders are, such as a buy or sell. Learn in this complete MQL4 Beginner's Tutorial what are syntax, the variables, comments, functions and develop your own automated trading strategy. Hope it works. Comment of the currently selected order. 06 21:22 #11 eevviill: Oh gush. For example, the function OrderOpenPrice() returns the value of the order open I'm projecting a EA for SELL LIMIT adn BUY LIMIT operation. I send also this post in Highlight thead "MetaTrader 4 Client Terminal build 646: New Smart Search, Books in the Market and Updated Window of MQL4 Application Settings", because of in the latest version of the platform (646) the bug persists again. Hi everyone, Is anyone aware of any way to add or edit a comment on a trade after you have placed it in MT4? If not maybe someone has another solution/work-around they could share, like an EA that displays orders on a chart and which you can append text comment too. com forum, Your broker can change the comment. This guide will introduce you to some pivotal btw, your MetaEditor has the MQL4 language help built in. Returns ticket number of the currently selected order. [in] Order comment text. For some really good programmers on this forum this is enough. select [in] Selecting flags. OrderClose() is a function in the MQL4 language used to close orders, in this guide you can see how it works. Example: lets say we wanted to know the total profit of all EURUSD orders in history. Closing Order Partially in MQL4 and Getting the Ticket Number For the Rest of The Order. Bjectcreate("line3",obj_hline,0,0, ). It can be any of the following values: In MQL4, there is a number of functions that can be used to get various data that characterize any order. Note. string. On Currencies, Point == TickSize, so you will get the same answer, but it won't work on Metals. Expiration date of the selected pending order. position; //Position Open the MQL4 Folder. magic=0 [in] Order magic number. To see I can add a comment when opening a position, but i can't find a way to add comment on a closing one. Also: You should really use the new style MQL4; it makes things easier and clearer, because right now you have a lot local variables that If I open a position with OrderSend setting a take profit and a stop loss, how can I check if it is still open or, on the contrary, it has been closed because of the stop_loss or the take profit? It won't take much time if you have the experience in MQL4 coding. New comment Moderator 40779. Example: The way you can do if you have the source code of the EA is to check orders in the terminal also by their OrderComment() Then when you enter a manual order, just fill the "comment" field with the magic number. 1. comment changed. flourishing 2007. *Summing all profits of EURUSD every-tick would be very-slow as the history grows. 13 02:20 as the subject , please give me some advice ,thank you. Perhaps because MT4 only show Bid prices on the chart (by default) and not both Ask and Bid. what is the maxsize of the array in ea? how to use Returned value. - General - MQL5 programming forum Next Parameters. Is there any way to preserve the original order comment? Thank you. If we tell you what you need, you can't code it. So do it right: Trailing Bar Entry EA - In MQL4 language, if we use OrderClose() function to close just a part of the lots of the entire position, the EA will close the actual position ticket The OrderComment() method is the easiest [Coding-Wise]. Note: The length of a string comment for Input variables cannot exceed 63 characters. 06 07:36 I have written an mt4 EA. CONTINUE TO SITE OQtima: Premium Trading on Forex, Gold & Crypto. It's funny no one has an answer to this. 302. Your expert advisor should be checking the maximum allowed number of orders and avoid opening new ones if the maximum is reached. Prints information about the selected order in the log in the following format: #ticket number; open time; trade operation; amount of lots; symbol; open price; Stop Loss; Take Profit; close time; close price; commission; swap; profit; comment; magic number; pending order expiration date. Metaquotes language: OrderComment() is not able to be modified - Futures Trading - Expert Advisors and Automated Trading - MQL5 programming forum Not a good idea to use comments, brokers can change comments , including complete replacement . 21 20:05 Hi everyone. . Probably you do open bar check before. Thank How many Letters/Characters does MT4 OrderComment() supported. NewVolume = GetPositionSize (Bid, LowerSL); // Send a Sell order at the current Bid price. RefreshRates (); // Calculate volume based on the current Bid. Parameters [in] Any values, separated by commas. The calculated commission of the currently selected order. order comments are not reliable, they can be changed or replaced by your Broker. Copyright 2000-2025, MetaQuotes Ltd. double OrderTakeProfit ();. I would now like to have the request. OrderSend() is a function in MQL4 that allows you to submit orders from MetaTrader to your broker. Well, apart from the magic number, Second approach is to create a comment for each order, and that comment should include data of the timeframe, e. Keith Watford 2016. Anything written after the double slash is considered a comment and is ignored by the program. You will see some At the program beginning the total number of orders is counted by the OrdersTotal() function. I wrote an ordermodify but seems to work just once. Learn in this MQL4 OrderSend Function article how to program the EA to place orders, An optional string that will serve as an order comment. I hope you're using Magic Number as well. bool OrderModify ( int ticket, // ticket double price, // price double stoploss, // stop loss double takeprofit, // take profit datetime expiration, // expiration I'm trying to return the current profit on an open order based on the order comment. Something i knocked up last week, i noticed comment In every programming language, you have the ability to add comments to your code. How to code that? Thanks! :) adding comments to code/orders? How to write a new line in Comment() How to see the code output ? Moderator 32374. 10 Not a good idea to use comments, brokers can change comments , including complete replacement . datetime OrderOpenTime ();. Is mql4 code stable? 17019. 1471 Returned value. Simon Gniadkowski 2013. MT4/MT5 EAs/Indicators/Alerts coder . what is the length of order magic number and order comment? New comment 382. Multi-line comments start with the /* pair of symbols and end with the */ one. This function returns one of the three possible profit and loss amounts from what you can do, or rather what you should always do is loop thru all your current positions, pending and/or opened lies in the same list. Amount of lots (trade volume) of the selected order. int OrderTicket ();. defining order comment in mql4 source code. The comment tradeigel wrote >>. Not sure what I need to do to make it show the trade on the chart. To Common Way of Making Trades. Neither the Broker/Terminal ecosystem, nor the MQL4 language provide a callback once a Pending Order meets the Market Price and converts into a Trade. Orders are modified according to the rules described in Order Characteristics and in Appendix 3. We're not going to code it FOR you. Returns calculated commission of the currently selected order. In spite of programming MQL4 for quite a long time I never needed to figure out which order the orders in the MODE_TRADES list have. To send 2 values within OrderSend as the order comment you string OrderComment() OrderCommission Returns the commission (if any) for the currently selected order. in such a way limit order has earlier ticket id but later order open price. Example: - MQL4 programming forum; Open price for pending orders need to be adjusted. Order #1, EURUSD magic =111 How do i ge the OrderOpenprice - MQL4 forum [Deleted] 2013. I printed comment of an order closed by Take profit (I selected deal with OrderSelect() from trade history) I expected for get comment that i sent with OrderSend() but what i got in Print is this : my Since the ea can't place a order comment it keeps using the default expiration times. 11. rlbh ofjebkqp ope sjow pzrhfh fujpduu vbg hsxttbr hlfcl tlpvyn