Forex



Go Back   Forex Trading > Programming > MetaTrader
Forex Forum Register More recent Calendar Advertising Others Help






Register
Welcome to Forex-TSD!, one of the largest Forex forums worldwide, where you will be able to find the most complete and reliable Forex information imaginable.

From the list below, select the forum that you want to visit and register to post, as many times you want. It’s absolutely free. Click here for registering on Forex-TSD.

Exclusive Forum
The Exclusive Forum is the only paid section. Once you subscribe, you will get free access to real cutting-edge Trading Systems (automated and not), Indicators, Signals, Articles, etc., that will help and guide you, in ways that you could only imagine, with your Forex trading.
  • Elite Section
    Get access to private discussions, specialized support, indicators and trading systems reported every week.
  • Advanced Elite Section
    For professional traders, trading system developers and any other member who may need to use and/or convert, the most cutting-edge exclusive indicators and trading systems for MT4 and MT5.
See more

Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 01-13-2008, 11:49 PM
Dan7974's Avatar
Senior Member
 
Join Date: Jul 2006
Posts: 267
Dan7974 is on a distinguished road
Expiration

How do I code the expiration for my pending Orders?

i.e.,

PHP Code:
OrderSend(Symbol(),OP_BUYSTOP,0.1,Ask,25,Ask-50*Point,Ask+50*Point,"",0,ExpirationGreen); 
What do I set in the
PHP Code:
Expiration 
to make my pending Orders Delete in 1 hour?
__________________
God Bless Everyone, and their trading logic.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #2 (permalink)  
Old 01-13-2008, 11:55 PM
codersguru's Avatar
Senior Member
 
Join Date: Oct 2005
Posts: 994
codersguru has a spectacular aura aboutcodersguru has a spectacular aura aboutcodersguru has a spectacular aura about
Set the time from now in seconds.
For example if you want the order to expire after 30 minutes then you have to use this:

PHP Code:
int expire_at TimeCurrent() + (30 60 ); 
Quote:
Originally Posted by Dan7974 View Post
How do I code the expiration for my pending Orders?

i.e.,

PHP Code:
OrderSend(Symbol(),OP_BUYSTOP,0.1,Ask,25,Ask-50*Point,Ask+50*Point,"",0,ExpirationGreen); 
What do I set in the
PHP Code:
Expiration 
to make my pending Orders Delete in 1 hour?
__________________
Hope it helps !
Coders' Guru
Senior MQL programmer:
www.xpworx.com/custom.htm
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #3 (permalink)  
Old 01-14-2008, 01:40 AM
Dan7974's Avatar
Senior Member
 
Join Date: Jul 2006
Posts: 267
Dan7974 is on a distinguished road
Thank You so much!!!!!!!
It works!!!
__________________
God Bless Everyone, and their trading logic.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #4 (permalink)  
Old 02-09-2008, 03:55 PM
fxgrm's Avatar
Senior Member
 
Join Date: Mar 2007
Posts: 114
fxgrm is on a distinguished road
How to code an EA to show max margin level?

Hello:

Can someone tell me how to add the code so an EA will show max margin level % inccurred?

Thanks

Last edited by fxgrm; 02-13-2008 at 01:33 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #5 (permalink)  
Old 02-09-2008, 04:31 PM
Administrator
 
Join Date: Sep 2005
Posts: 20,083
Blog Entries: 243
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
It should be on this thread How to LOCK/Encrypt EA
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #6 (permalink)  
Old 02-09-2008, 05:42 PM
fxgrm's Avatar
Senior Member
 
Join Date: Mar 2007
Posts: 114
fxgrm is on a distinguished road
Q for Newdigital or other?

Dumb question I'm sure.

Can you tell me the easiest way to convert EA's ex4 to an mq4 file?

Thanks

Last edited by fxgrm; 02-13-2008 at 01:24 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #7 (permalink)  
Old 02-09-2008, 06:11 PM
Administrator
 
Join Date: Sep 2005
Posts: 20,083
Blog Entries: 243
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
MetaEditor.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #8 (permalink)  
Old 02-09-2008, 06:33 PM
fxgrm's Avatar
Senior Member
 
Join Date: Mar 2007
Posts: 114
fxgrm is on a distinguished road
Hi newdigital:

I understanf now that ex4 protects file so can't be undone. Thanks

Sorry for all the basic questions.

Cheers

Last edited by fxgrm; 02-13-2008 at 01:26 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #9 (permalink)  
Old 02-09-2008, 07:11 PM
Administrator
 
Join Date: Sep 2005
Posts: 20,083
Blog Entries: 243
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
First of all you must decide: is it EA or indicator?
Because everything should be placed in different folders ...
This post will help you http://www.forex-tsd.com/92940-post7.html
So, after placing your, let's say, EA in right foder you must open MetaEditor.
It is more good to open MetaEditor from MetaTrader.
I am having few copies of Metatrader in my PC so if I do not want to be confused about which MetaEditor for which Metatrader so I am openning MetaEditor from Metatrader: right mouse click on any indicator and select "Modify". MetaEditor will be opened.

Find your EA (or indicator) in MetaEditor.
Use this one:

12wwd.jpg

or this menu:

12wwd1.jpg

And open your EA (or indicator) and compile it. Just click on this one:

12wwd2.jpg

If you have any errors so you will see it here:

12wwd3.jpg

If no error so you can find your ex4. Do you remember the forder where you placed your EA or indicator?
This post http://www.forex-tsd.com/92940-post7.html

So go to the same folder and you will find your ex4 file.

If you want to change your ex4? Do the same - compile the code and MetaEditor will generate new ex4.

Because Metatrader is using ex4 files.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #10 (permalink)  
Old 02-09-2008, 07:14 PM
fxgrm's Avatar
Senior Member
 
Join Date: Mar 2007
Posts: 114
fxgrm is on a distinguished road
Thumbs up Newdigital

Thanks a million. You do an awesome job on this forum!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
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
Setting An Expiration Date On Indicator emersond Indicators - Metatrader 4 13 08-01-2009 05:46 PM
EA expiration date jyrik Expert Advisors - Metatrader 4 6 04-12-2007 05:32 PM
Place expiration on EA troydavis1010 General Discussion 1 04-10-2007 10:05 PM


All times are GMT. The time now is 02:46 AM.



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