• Home
  • Forums
  • Trades
  • News
  • Calendar
  • Market
  • Brokers
  • Login
  • Join
  • User/Email: Password:
  • 12:37am
Menu
  • Forums
  • Trades
  • News
  • Calendar
  • Market
  • Brokers
  • Login
  • Join
  • 12:37am
Sister Sites
  • Metals Mine
  • Energy EXCH
  • Crypto Craft

Options

Bookmark Thread

First Page First Unread Last Page Last Post

Printable Version

Similar Threads

Trade Panel and Dashboard VR Stealth Pro 85 replies

Need trade management panel indicator 0 replies

Need recommendation on Panel/EA to place Hedge order 0 replies

Trade Opportunity Panel - WSS 0 replies

  • Trading Discussion
  • /
  • Reply to Thread
  • Subscribe
  • 79
Attachments: Hedge Trade-panel
Exit Attachments

Hedge Trade-panel

  • Last Post
  •  
  • 1 23Page 456 17
  • 1 3Page 45 17
  •  
  • Post #61
  • Quote
  • Feb 13, 2018 6:50am Feb 13, 2018 6:50am
  •  renkotop
  • Joined Nov 2015 | Status: Member | 893 Posts | Online Now
Quoting Nicholishen
Disliked
I know, I know... we've all said it before, hedging is f*** stupid because it costs you double in fees, right? Well that's actually not (always) the case. There's a neat little hidden gem in MT that's almost entirely undocumented and almost never used by developers (ever) that's called OrderCloseBy. What this function does is takes hedged orders and reconciles the transactions as netted. This allows you to do some neat things we'll talk about in a minute, but for now it's important to understand that if you use this method you are not charged double...
Ignored
@Nicholishen: The best trade Panel I' ve ever seen! Thank you
  • Post #62
  • Quote
  • Apr 5, 2018 1:50pm Apr 5, 2018 1:50pm
  •  v2vboni
  • Joined Sep 2015 | Status: ob-la-di, ob-la-da, life goes on... | 3,012 Posts
Quoting Nicholishen
Disliked
In case anyone is interested, here is the logic for reconciling all hedged positions as netting....
Ignored
Thanks for this one
Intelligence is the ability to adapt to change. -- Stephen Hawking
  • Post #63
  • Quote
  • Edited at 6:15pm Apr 5, 2018 4:47pm | Edited at 6:15pm
  •  v2vboni
  • Joined Sep 2015 | Status: ob-la-di, ob-la-da, life goes on... | 3,012 Posts
Quoting Nicholishen
Disliked
In case anyone is interested, here is the logic for reconciling all hedged positions as netting. void ReconcileHedgeOrders() { for(int i=OrdersTotal()-1;i>0&&!IsStopped();i--) { if(OrderSelect(i,SELECT_BY_POS) && OrderSymbol()==_Symbol && OrderType()<2 && (!m_locked_magic || OrderMagicNumber() == MAGIC) ) { int type = OrderType(); int ticket = OrderTicket(); for(int j=i-1;OrderSelect(j,SELECT_BY_POS);j--) { if(OrderSymbol()==_Symbol && OrderType()<2 && OrderType()!=type && (!m_locked_magic || OrderMagicNumber() == MAGIC) ) { if(!OrderCloseBy(OrderTicket(),ticket))...
Ignored

Hi Nicholishen,

Just made a script out of your shared code for reconciling all hedged positions as netting...
Warning: Not fully tested.

Attached Image

Attached File
File Type: ex4 FXV_Close-Orders-On-Chart.ex4   199 KB | 450 downloads


regards...



For noobs: put the script under " /MQL4/Scripts" folder
Intelligence is the ability to adapt to change. -- Stephen Hawking
  • Post #64
  • Quote
  • Apr 6, 2018 10:18am Apr 6, 2018 10:18am
  •  Merka
  • Joined Jan 2016 | Status: Member | 1,289 Posts
Sorry for the newbie question.
I didn't understand what mean "reconcile" "netted"?
Let say for example I have 1 lot buy and 1 lot sell.
What will be the result of the EA and script for closing all trades?
Thanks
  • Post #65
  • Quote
  • Apr 6, 2018 1:31pm Apr 6, 2018 1:31pm
  •  Nicholishen
  • Joined Jul 2005 | Status: zzzzzzzzzzzzzzzzzzzzzzzzz zzzzzzzzzz | 1,289 Posts
Quoting Merka
Disliked
Sorry for the newbie question. I didn't understand what mean "reconcile" "netted"? Let say for example I have 1 lot buy and 1 lot sell. What will be the result of the EA and script for closing all trades? Thanks
Ignored
Netted - Orders that are technically closed in net position, but still show up as open (and separate) orders on the platform. Example: order1: buy 1 lot [in], order2: sell 1 lot[out]

reconcile - send the closeby command to the broker server to tell it to reconcile the netted orders as one position [in,out] rather than two separate positions.
2
  • Post #66
  • Quote
  • Apr 11, 2018 5:29pm Apr 11, 2018 5:29pm
  •  Merka
  • Joined Jan 2016 | Status: Member | 1,289 Posts
Quoting Nicholishen
Disliked
{quote} Netted - Orders that are technically closed in net position, but still show up as open (and separate) orders on the platform. Example: order1: buy 1 lot [in], order2: sell 1 lot[out] reconcile - send the closeby command to the broker server to tell it to reconcile the netted orders as one position [in,out] rather than two separate positions.
Ignored
Thanks Nicholishen

Your trade panel is suitable for only intraday trades or is useful also for trades carried over some days?
I use Oanda and I'm changed only the spread + rollover fees because my trades last 3 or 5 days on average so I'm trying to understand if "OrderCloseBy" is useful in my case.

Thanks
  • Post #67
  • Quote
  • Apr 11, 2018 9:58pm Apr 11, 2018 9:58pm
  •  Nicholishen
  • Joined Jul 2005 | Status: zzzzzzzzzzzzzzzzzzzzzzzzz zzzzzzzzzz | 1,289 Posts
Quoting Merka
Disliked
{quote} Thanks Nicholishen Your trade panel is suitable for only intraday trades or is useful also for trades carried over some days? I use Oanda and I'm changed only the spread + rollover fees because my trades last 3 or 5 days on average so I'm trying to understand if "OrderCloseBy" is useful in my case. Thanks
Ignored
Ordercloseby only works on a broker who allows hedging and I don't think that Oanda offers any hedging accounts.
  • Post #68
  • Quote
  • Apr 11, 2018 11:20pm Apr 11, 2018 11:20pm
  •  Merka
  • Joined Jan 2016 | Status: Member | 1,289 Posts
Quoting Nicholishen
Disliked
{quote} Ordercloseby only works on a broker who allows hedging and I don't think that Oanda offers any hedging accounts.
Ignored
Sorry I forgot to mention that I have an hedge account with Oanda.
  • Post #69
  • Quote
  • Apr 11, 2018 11:56pm Apr 11, 2018 11:56pm
  •  carddard
  • Joined Jan 2017 | Status: Member | 263 Posts
Quoting Nicholishen
Disliked
I know, I know... we've all said it before, hedging is f*** stupid because it costs you double in fees, right? Well that's actually not (always) the case. There's a neat little hidden gem in MT that's almost entirely undocumented and almost never used by developers (ever) that's called OrderCloseBy. What this function does is takes hedged orders and reconciles the transactions as netted. This allows you to do some neat things we'll talk about in a minute, but for now it's important to understand that if you use this method you are not charged double...
Ignored
Have you thought about automating the entries?
  • Post #70
  • Quote
  • Apr 12, 2018 2:49am Apr 12, 2018 2:49am
  •  Nicholishen
  • Joined Jul 2005 | Status: zzzzzzzzzzzzzzzzzzzzzzzzz zzzzzzzzzz | 1,289 Posts
Quoting carddard
Disliked
{quote} Have you thought about automating the entries?
Ignored
This isn't a system or a strategy, it's a tool to assist manual traders with making smarter positions.
1
  • Post #71
  • Quote
  • Apr 24, 2018 2:46pm Apr 24, 2018 2:46pm
  •  Merka
  • Joined Jan 2016 | Status: Member | 1,289 Posts
Hi Nicholishen

I'm trying your tool on Oanda Hedge demo account but it look like is not working as per pictures below.
Do you know why?
Thanks
Attached Images (click to enlarge)
Click to Enlarge

Name: Untitled 24-04-2018.png
Size: 66 KB Click to Enlarge

Name: Untitled 1 24-04-2018.png
Size: 77 KB
  • Post #72
  • Quote
  • Apr 24, 2018 4:24pm Apr 24, 2018 4:24pm
  •  available
  • | Commercial Member | Joined Nov 2014 | 327 Posts
Have you tried with other brokers (if you have any)? Worked on my hotforex platform, there could be an installation problem
  • Post #73
  • Quote
  • Edited at 5:27pm Apr 24, 2018 4:35pm | Edited at 5:27pm
  •  Merka
  • Joined Jan 2016 | Status: Member | 1,289 Posts
Quoting available
Disliked
Have you tried with other brokers (if you have any)? Worked on my hotforex platform, there could be an installation problem
Ignored
Hi
I'm wondering if the problem is related to be a demo account.
I will try on other brokers as well.
Your hotforex account is it demo or live?
Thanks

Update: Just opened a hedge demo account on "XM" and all is working properly
  • Post #74
  • Quote
  • Apr 25, 2018 12:44pm Apr 25, 2018 12:44pm
  •  Nicholishen
  • Joined Jul 2005 | Status: zzzzzzzzzzzzzzzzzzzzzzzzz zzzzzzzzzz | 1,289 Posts
This tool uses hedging, and as such will not work with a broker that does not allow hedging, ie. Oanda et al.
  • Post #75
  • Quote
  • Apr 25, 2018 2:13pm Apr 25, 2018 2:13pm
  •  Merka
  • Joined Jan 2016 | Status: Member | 1,289 Posts
Quoting Nicholishen
Disliked
This tool uses hedging, and as such will not work with a broker that does not allow hedging, ie. Oanda et al.
Ignored
My Oanda account is definitely an hedge account as you can see from picture I have buy&sell trade opened at the same time and on the same instrument.
I don't know why is not working on Oanda but likely is working on XM that offer a higher leverage of 500:1 as well.
Thanks for your tool.
  • Post #76
  • Quote
  • Apr 25, 2018 11:13pm Apr 25, 2018 11:13pm
  •  Seunboi4u
  • Joined Aug 2016 | Status: Member | 64 Posts
any one can help me with working one thanks
  • Post #77
  • Quote
  • Aug 6, 2018 12:16am Aug 6, 2018 12:16am
  •  f3n_dy
  • | Joined Jul 2006 | Status: Member | 48 Posts
Quoting Nicholishen
Disliked
I know, I know... we've all said it before, hedging is f*** stupid because it costs you double in fees, right? Well that's actually not (always) the case. There's a neat little hidden gem in MT that's almost entirely undocumented and almost never used by developers (ever) that's called OrderCloseBy. What this function does is takes hedged orders and reconciles the transactions as netted. This allows you to do some neat things we'll talk about in a minute, but for now it's important to understand that if you use this method you are not charged double...
Ignored

awesome tools...mind to share mq4 ? thanks
  • Post #78
  • Quote
  • Aug 6, 2018 7:19am Aug 6, 2018 7:19am
  •  Nicholishen
  • Joined Jul 2005 | Status: zzzzzzzzzzzzzzzzzzzzzzzzz zzzzzzzzzz | 1,289 Posts
Quoting f3n_dy
Disliked
{quote} awesome tools...mind to share mq4 ? thanks
Ignored
I would share the source as long as you promise to openly share any modifications you make, deal?
  • Post #79
  • Quote
  • Aug 6, 2018 7:21am Aug 6, 2018 7:21am
  •  carddard
  • Joined Jan 2017 | Status: Member | 263 Posts
Quoting Nicholishen
Disliked
{quote} I would share the source as long as you promise to openly share any modifications you make, deal?
Ignored
Deal!
  • Post #80
  • Quote
  • Aug 6, 2018 9:48am Aug 6, 2018 9:48am
  •  f3n_dy
  • | Joined Jul 2006 | Status: Member | 48 Posts
Quoting Nicholishen
Disliked
{quote} I would share the source as long as you promise to openly share any modifications you make, deal?
Ignored
ok deal...i am not a coder..but i have some idea..if you think its good..lets develop it
  • Trading Discussion
  • /
  • Hedge Trade-panel
  • Reply to Thread
    • 1 23Page 456 17
    • 1 3Page 45 17
0 traders viewing now
  • More
Top of Page
  • Facebook
  • Twitter
About FF
  • Mission
  • Products
  • User Guide
  • Media Kit
  • Blog
  • Contact
FF Products
  • Forums
  • Trades
  • Calendar
  • News
  • Market
  • Brokers
  • Trade Explorer
FF Website
  • Homepage
  • Search
  • Members
  • Report a Bug
Follow FF
  • Facebook
  • Twitter

FF Sister Sites:

  • Metals Mine
  • Energy EXCH
  • Crypto Craft

Forex Factory® is a brand of Fair Economy, Inc.

Terms of Service / ©2021