Forex
Google

Go Back   Forex Trading > Programming > Metatrader Programming
Forex Forum Register FAQ Members List Calendar Search Today's Posts Mark Forums Read


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

Closed Thread
 
LinkBack (9) Thread Tools Display Modes
  #11 (permalink)  
Old 09-18-2007, 02:34 PM
newdigital newdigital is offline
Administrator
 
Join Date: Sep 2005
Posts: 14,365
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
- Trade context is busy: how to solve this problem.

- Trading Times Enhancement: very usefull code about only trade during certain periods.

- avoid plotting the EA on the wrong chart: some usefull codes about EA and certain timefame to trade.

- Use GlobalVariableGet() in an indicator: good thread with codes and explanation.

- List of Arrow Style and others like like fractal, circle, arrow up, arrow down and so on.

Last edited by newdigital : 02-17-2008 at 09:32 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #12 (permalink)  
Old 11-07-2007, 10:29 PM
bassco bassco is offline
Junior Member
 
Join Date: Oct 2007
Posts: 1
bassco is on a distinguished road
How do I code an EA to enter a trade at the open of a new candle?

Hi everyone,

Please forgive my ignorance, but I am new to the programming side of MQL4.
What I am trying to accomplish is enter one trade at the open of a new candle.
For example, if I had a 30min chart open, I would like to enter one trade at the open. Or if I had a 4hour chart open, how would I enter the trade at the open of that chart?

Also, I would like to enter only 1 trade at the open. I have tried a few commands and found it either entering the trade many times during the first minute, or not at all.

I have tried the "time current" function as well as "if minute = XXXX". The EA works when I backtest it, but when I try to put it on my live demo, it only works once in a while.

Any input would be greatly appreciated.
Thanks in advance.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #13 (permalink)  
Old 11-08-2007, 07:44 AM
newdigital newdigital is offline
Administrator
 
Join Date: Sep 2005
Posts: 14,365
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
Moved your post to this thread where you will find some links about how to code one trade oer candle etc.

besides there are some other threads:

Basic questions ...

How to open 1 trade per bar
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #14 (permalink)  
Old 12-28-2007, 07:08 AM
newdigital newdigital is offline
Administrator
 
Join Date: Sep 2005
Posts: 14,365
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
How to paint "Close[i]/High[i]" in seperate window.

How to code the expiration for pending orders.

DLL:
- MT4 Files Functions Replacement
- Create your own MetaTrader extension (dll) + video about how to do it.
- Net DLL wrapper
- dll tutorial for Visual Studio 2005

Last edited by newdigital : 03-14-2008 at 08:28 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #15 (permalink)  
Old 01-25-2008, 04:48 PM
newdigital newdigital is offline
Administrator
 
Join Date: Sep 2005
Posts: 14,365
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
NO Trade 2 hours before or 1 hour after news EA.

Last edited by newdigital : 02-17-2008 at 09:32 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #16 (permalink)  
Old 02-17-2008, 09:36 AM
newdigital newdigital is offline
Administrator
 
Join Date: Sep 2005
Posts: 14,365
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
hot keys in MetaTrader:

Secrets of Meta-Trader

Key event within mq4 programs

Hotkeys for Buy and Sell
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #18 (permalink)  
Old 03-17-2008, 03:00 PM
newdigital newdigital is offline
Administrator
 
Join Date: Sep 2005
Posts: 14,365
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
EA instant order requote problem: the thread with codes.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #19 (permalink)  
Old 03-26-2008, 09:10 AM
newdigital newdigital is offline
Administrator
 
Join Date: Sep 2005
Posts: 14,365
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
Timefilter:
- how to set EA's time in timefilter is on this post and this page.
- how to code timefilter in EAs (codes) is here.
- "Non-Trading Hours" on the screen fixing: example code; now it displays "Trading Hours" during trading hours and "Non-trading Hours" during non-trading hours. Thanks Locutus.
- how to code time filter: public thread.

Solution to computer restarts, keep those EAs running: some good suggestion about.

MM (money management) calculation, indicators, discussion, tools: calculate your lot size and so on. Original thread with several versions.

Magic number:
- Automatic Magic Function: small thread about how to do it.
- how to put magic number in EA: small elite section thread.
- magic number: small thread with explanation.

Last edited by newdigital : 04-08-2008 at 04:00 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Closed Thread


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

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

LinkBacks (?)
LinkBack to this Thread: http://www.forex-tsd.com/metatrader-programming/2333-dose-posible-creat-any-function-mql-code-posting-forum.html
Posted By For Type Date
EA Biblioteka This thread Refback 03-29-2008 12:05 PM
EA Biblioteka This thread Refback 02-26-2008 09:04 PM
EA Biblioteka This thread Refback 02-24-2008 01:24 PM
EA Biblioteka This thread Refback 02-20-2008 07:36 AM
EA Biblioteka This thread Refback 01-15-2008 12:19 PM
EA Biblioteka This thread Refback 10-28-2007 10:06 PM
EA Biblioteka This thread Refback 10-26-2007 03:40 AM
EA Biblioteka This thread Refback 10-17-2007 04:56 PM
EA Biblioteka This thread Refback 10-16-2007 07:16 PM


All times are GMT. The time now is 09:44 PM.