Forex
Google
New signals service!

Go Back   Forex Trading > Programming > Metatrader Programming


Register in Forex TSD!
Trading Systems Leaders in this forum (automated trading systems) are winning more than 3000 pips in a month (30000$ investing one lot every time).
Click here to register and get more information

Reply
 
LinkBack Thread Tools Display Modes
  #341 (permalink)  
Old 03-26-2008, 11:34 AM
Linuxser's Avatar
Moderator
 
Join Date: May 2006
Location: Helliconia (Spring)
Posts: 3,322
Blog Entries: 46
Linuxser has disabled reputation
Quote:
Originally Posted by timebandit View Post
Hi,
When an order is open it is assigned a ticket number. When this order is modified through an EA (i.e. the EA closes a portion of the trade) does the old ticket get changed to a new ticket number?
I'm still a rookie at all this programming stuff so any help is greatly appreciated.
Thanks
Bob
It shouldn't be changed.
__________________
Elite Manual Trading | Portfolio | Calendar | Suggestions to improve the forum | My Blog

Remember: Signatures must have three lines as maximum
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #342 (permalink)  
Old 03-26-2008, 01:38 PM
Mistigri's Avatar
Junior Member
 
Join Date: Mar 2006
Location: SLC
Posts: 23
Mistigri is on a distinguished road
If you close partial lots then yes a new ticket number is generated, if you only update stops then the tikcer number will not change.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #343 (permalink)  
Old 03-27-2008, 05:00 AM
MANSTIR's Avatar
Senior Member
 
Join Date: Nov 2007
Posts: 143
MANSTIR is on a distinguished road
Thumbs up

Quote:
Originally Posted by Linuxser View Post
Sorry, EA code? maybe here.

Auto pivot trade
thanks linuxser for ya kindness...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #344 (permalink)  
Old 03-27-2008, 10:23 PM
Senior Member
 
Join Date: Oct 2007
Posts: 224
Dave137 is on a distinguished road
Smile Error #130

What does this mean?? It relates to placing a trade with the EA.

Dave
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #345 (permalink)  
Old 03-27-2008, 10:33 PM
Member
 
Join Date: Nov 2005
Posts: 54
4xCoder is on a distinguished road
It means bad stop price. In orderSend, the stop is a price and must be at least 10 pips below the entry price for buy or 10 pips above the entry price for sell
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #346 (permalink)  
Old 03-27-2008, 10:55 PM
Linuxser's Avatar
Moderator
 
Join Date: May 2006
Location: Helliconia (Spring)
Posts: 3,322
Blog Entries: 46
Linuxser has disabled reputation
Hi,

Error table error for MQL4: Error codes - MQL4 Documentation

ERR_INVALID_STOPS130Invalid stops.
__________________
Elite Manual Trading | Portfolio | Calendar | Suggestions to improve the forum | My Blog

Remember: Signatures must have three lines as maximum
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #347 (permalink)  
Old 03-27-2008, 11:30 PM
Senior Member
 
Join Date: Oct 2007
Posts: 224
Dave137 is on a distinguished road
Smile

Thanks! I am testing with several modifications/additions to my EA now. It worked with North Finance and Interbankfx, but did not work with the new brokerage firm that North Finance is promoting now - FXpro.com. They have some great features and are faster and are Euro regulated, and they went to a fifth decimal place on some currencies. I suspect Fxpro's MT4 platform has had modifications to it to support the additional decimal place, consequently as I transferred over my reliable EA's to their platform, they no longer would work. The error 130 was what I was getting.

Dave
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #348 (permalink)  
Old 03-28-2008, 03:31 AM
Senior Member
 
Join Date: Oct 2007
Posts: 224
Dave137 is on a distinguished road
Red face

I give up with FXPro's demo accounts. No matter what I do to enhance or fix the stoploss in my EA that works perfectly on other brokerage firms platform - It still gives me the same #130 error. I give up!!

Dave
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #349 (permalink)  
Old 03-28-2008, 11:13 PM
Junior Member
 
Join Date: Oct 2006
Posts: 24
natsirte is on a distinguished road
build my own moving average

Hi



I'd like to know how to build my own moving average with the average of 4 indicators.




double ma = iMA(NULL, 0, 14, 0, MODE_EMA, PRICE_CLOSE,Current + 0);
double ma_m15 = iMA(NULL, PERIOD_M15, 14, 0, MODE_EMA,PRICE_CLOSE, Current + 0);
double ma_m30 = iMA(NULL, PERIOD_M30, 14, 0, MODE_EMA,PRICE_CLOSE, Current + 0);
double ma_m60 = iMA(NULL, PERIOD_H1, 14, 0, MODE_EMA,PRICE_CLOSE, Current + 0);



double var1 = ma , var2 = ma_m15 , var3 = ma_m30 , var4=ma_m60 ;

double var_myMA = (var1 + var2 + var3 + var4)/4;



How can I draw var_myMA in the main window? I don't know how to use ObjectCreate()



Best regards
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #350 (permalink)  
Old 03-29-2008, 02:21 AM
Linuxser's Avatar
Moderator
 
Join Date: May 2006
Location: Helliconia (Spring)
Posts: 3,322
Blog Entries: 46
Linuxser has disabled reputation
Hi,

Take a look at this thread. You also could use the Moving Average indcaitor code as example, or the MACD code and so on.

Quote:
SetIndexStyle(0,DRAW_LINE);
SetIndexBuffer(0,var_myMA);
I highly recommend you to read this section: http://www.forex-tsd.com/lessons/
__________________
Elite Manual Trading | Portfolio | Calendar | Suggestions to improve the forum | My Blog

Remember: Signatures must have three lines as maximum
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Bookmarks

Tags
automated close order, close, eas, forex, learn mql4, learn mql4 video, mql4 learning, OrderCloseBy, profit, reach, secure profit function, T101_v1.11_orest_IBFXm.mq4, learning mql4

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Learning Cycles For New Traders Dan7974 General Discussion 350 01-18-2008 07:04 PM
Learning to code for autotrading GoatT Metatrader Programming 8 01-10-2007 09:55 PM
Self learning expert mrtools Expert Advisors - Metatrader 4 32 10-22-2006 06:29 PM


All times are GMT. The time now is 12:19 PM.



Search Engine Friendly URLs by vBSEO 3.2.0 ©2008, Crawlability, Inc.