EA for adding limit-orders

Place your new trading idea here to see if someone can automate it.
User avatar
Gertje
Trader
Posts: 1936
Joined: Mon Dec 12, 2011 1:17 pm
Location: Middle of the Netherlands

EA for adding limit-orders

Post by Gertje »

renexxxx » Thu May 31, 2018 7:08 pm wrote:
Gertje » Thu May 31, 2018 10:51 pm wrote: Now to get rid of these trade comments...... :arrrg:
You want to get rid of these "[tp]"'s?

Try this...
Not sure if you understood my sarcasm, I was relating to the warning built in by Steve. :smile:
I just need to remove the comments from PoS, so no harm done.

Last night TradeDuplicator worked like a charm, exactly what I was looking for!

I'll try the latest version, thanks again!
:!!:
User avatar
Gertje
Trader
Posts: 1936
Joined: Mon Dec 12, 2011 1:17 pm
Location: Middle of the Netherlands

EA for adding limit-orders

Post by Gertje »

renexxxx » Thu May 31, 2018 7:08 pm wrote:
Gertje » Thu May 31, 2018 10:51 pm wrote: Now to get rid of these trade comments...... :arrrg:
You want to get rid of these "[tp]"'s?

Try this...
Now I see what you mean. :arrrg:

I was thinking it didn't copy the ordercomment at all, hence the message from PoS.
But instead, it copies the comment perfectly, including the TP part that Empty4 adds to the comment.

The last version still copies the [tp] comment, is it possible to remove the comment at all?
I'm running PoS without comments, to be able to enter manual orders.
:!!:

EDIT: I tried to remove all mention of 'ordercomment' from the EA, but got an 'sendorderreliable' error in return.
So much for my programming skills... :arrrg:
User avatar
renexxxx
Trader
Posts: 860
Joined: Sat Dec 31, 2011 3:48 am

EA for adding limit-orders

Post by renexxxx »

Hi Gertjan,

Didn't realize that your original orderComment was blank. The built-in StringSubstr() function doesn't do what you expect if the length parameter is 0.

Code is in Post 1 of this thread.
User avatar
Gertje
Trader
Posts: 1936
Joined: Mon Dec 12, 2011 1:17 pm
Location: Middle of the Netherlands

EA for adding limit-orders

Post by Gertje »

renexxxx » Fri Jun 01, 2018 10:55 am wrote:Hi Gertjan,

Didn't realize that your original orderComment was blank. The built-in StringSubstr() function doesn't do what you expect if the length parameter is 0. Anyway, try the attached version.
Works like a charm Rene, thanks!!
:!!:
WillemJvR
Trader
Posts: 14
Joined: Tue Jan 17, 2017 4:11 pm

EA for adding limit-orders

Post by WillemJvR »

renexxxx » Fri Jun 01, 2018 12:55 pm wrote:Hi Gertjan,

Didn't realize that your original orderComment was blank. The built-in StringSubstr() function doesn't do what you expect if the length parameter is 0. Anyway, try the attached version.

:hi:
Hi Rene .. is it possible that i can try it aswell i attached to my demo account but is not working

REgards

Willie
User avatar
ThaiGuy
Trader
Posts: 17
Joined: Mon Apr 29, 2013 6:33 am

EA for adding limit-orders

Post by ThaiGuy »

wow this looks awesome, great thinking gertje and superfast code support from rene!!

i wont give it a shot myself yet, hence i look forward to more positive comments from gertje, and maybe there can be a PoS_v1E-LimitOrders ? I have no idea how to make 2 EA's work/interact with eachother haha :)
User avatar
renexxxx
Trader
Posts: 860
Joined: Sat Dec 31, 2011 3:48 am

EA for adding limit-orders

Post by renexxxx »

To avoid confusion, I have moved the "final" version of TradeReplicator to Post 1 of this thread and removed any other versions in earlier posts.
User avatar
Gertje
Trader
Posts: 1936
Joined: Mon Dec 12, 2011 1:17 pm
Location: Middle of the Netherlands

EA for adding limit-orders

Post by Gertje »

WillemJvR » Mon Jun 04, 2018 5:20 am wrote:
:hi:
Hi Rene .. is it possible that i can try it aswell i attached to my demo account but is not working

REgards

Willie
Hi Willie,

What do you want the EA to do?
User avatar
Gertje
Trader
Posts: 1936
Joined: Mon Dec 12, 2011 1:17 pm
Location: Middle of the Netherlands

EA for adding limit-orders

Post by Gertje »

renexxxx » Mon Jun 04, 2018 7:27 am wrote:To avoid confusion, I have moved the "final" version of TradeReplicator to Post 1 of this thread and removed any other versions in earlier posts.
Renee,

Sorry to bother you [again], but I can't seem to load the EA to a newer build of Empty4.
I tried compiling and got the following message; 'ordersendreliable' function not defined.
The EA has worked flawlessly since you wrote it, untill I tried to add it to a new installation.

Any idea's?
:arrrg: :arrrg: :arrrg:
User avatar
renexxxx
Trader
Posts: 860
Joined: Sat Dec 31, 2011 3:48 am

EA for adding limit-orders

Post by renexxxx »

You must copy the OrderReliable.mqh file (from Post 1) into the \Include folder. When TradeReplicator.mq4 is compiled, the pre-compiler tries to insert the contents of OrderReliable.mqh into the main code, before the whole lot is compiled and a .ex4 file is generated.

Good luck!
Post Reply

Return to “Ideas for Possible Automation”