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

Options

Bookmark Thread

First Page First Unread Last Page Last Post

Print Thread

Similar Threads

Can someone add an MTF option on this stepma? 0 replies

Can someone please add email capability to this alert? 4 replies

Can someone please add an email alert to this solarwinds indicator? 1 reply

Can Someone Please Add An Alert To This Indicator 14 replies

Help please ....can someone add email alert? 1 reply

  • Platform Tech
  • /
  • Reply to Thread
  • Subscribe
  • 2
Attachments: Can someone please add time option to this ea?
Exit Attachments
Tags: Can someone please add time option to this ea?
Cancel

Can someone please add time option to this ea?

  • Post #1
  • Quote
  • First Post: Jan 6, 2010 10:36am Jan 6, 2010 10:36am
  •  gangsta1
  • | Commercial Member | Joined Jul 2009 | 159 Posts
I need to be able to set the time the EA trades?

Any help would be greatly appreciated!
Attached File(s)
File Type: ex4 Gangsta1_noBuffer.ex4   8 KB | 198 downloads
  • Post #2
  • Quote
  • Jan 6, 2010 11:14am Jan 6, 2010 11:14am
  •  Rbi
  • | Joined Jan 2009 | Status: Member | 68 Posts
What you have posted is an ex4 file which is the executable...

you would need to post the source code to do anything to the EA... the file should end in .mq4!
 
 
  • Post #3
  • Quote
  • Jan 6, 2010 1:05pm Jan 6, 2010 1:05pm
  •  n.forex
  • | Joined Nov 2009 | Status: Member | 14 Posts
Hi

This code will let the EA work from 00:00 to 10:00 , and u can control by the time.


Inserted Code
extern string l="Working Hours";
extern int StartHour=0;
extern int EndHour=10;

int start()
  {
if(Hour()<StartHour||Hour()>EndHour){return(0);} //write this code at the begining 






// Write the rest of the code





   return(0);
  }
 
 
  • Post #4
  • Quote
  • Jan 6, 2010 2:20pm Jan 6, 2010 2:20pm
  •  gangsta1
  • | Commercial Member | Joined Jul 2009 | 159 Posts
thats great, thank you.

I also attached the correct file!
Attached File(s)
File Type: mq4 Gangsta1.mq4   9 KB | 199 downloads
 
 
  • Post #5
  • Quote
  • Last Post: Sep 28, 2010 10:39pm Sep 28, 2010 10:39pm
  •  hifromeddie
  • | Joined Jul 2010 | Status: Member | 22 Posts
If I change the stop loss in this EA, it does not open any trades.

So I have to keep the stop loss at 150.

But that is too high because I then end up with several -$150 (for $1 per lot) and several -$1500 (for $10 per lot).

The take profit can be adjusted to as low as 5 pips (and I end up with several $50 wins) and the EA still works and opens trades. But all the -150 pips keep me from gaining any ground with this EA.

As I said if I change the stoploss to anything but 150 the EA won't open any trades.

I tried changing the 150 in the mq4 code to a lower stop loss, but that too did not work because then the EA would not open trades.

I don't know anything about coding otherwise I might be able to fix it.
 
 
  • Platform Tech
  • /
  • Can someone please add time option to this ea?
  • Reply to Thread
0 traders viewing now
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 / ©2023