Forex



Go Back   Forex Trading > Discussion Areas > Metatrader 4
Forex Forum Register More recent Blogs 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
  #31 (permalink)  
Old 09-02-2009, 07:26 AM
Junior Member
 
Join Date: Jan 2009
Posts: 2
ohruj is on a distinguished road
Lightbulb Need script for modifying stop-loss by this indicator...

I Need script that modify your orders by updating the stop loss in line with the i_HighLow value. I trade by moving my stop loss to the boder of i-HighLow until I get stopped out in profit but I have to keep changing it manually. If the script can do this would be very usefull.

Method :

If open BUY position moving stoploss to highest high line (orange)
If open Sell position moving stoploss to lowest low line (blue)

Thanks.
Attached Files
File Type: mq4 i-HighLow_2.mq4 (2.3 KB, 14 views)
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
  #32 (permalink)  
Old 10-01-2009, 02:08 AM
xtream's Avatar
Junior Member
 
Join Date: Jul 2006
Posts: 2
xtream is on a distinguished road
Move lines for SL, TP and Pending B or S

I need an indicator where I could drag and drop horizontal lines for SL, TP and Pending Orders.

Please check attached jpeg
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
  #33 (permalink)  
Old 10-01-2009, 02:27 AM
xtream's Avatar
Junior Member
 
Join Date: Jul 2006
Posts: 2
xtream is on a distinguished road
Moving lines for SL, TP and pending orders

Image failed to upload on the start of thread. here it is
Attached Images
File Type: png magic lines.PNG (93.0 KB, 37 views)

Last edited by xtream; 10-01-2009 at 02:35 AM. Reason: Failed to upload
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
  #34 (permalink)  
Old 10-01-2009, 04:54 AM
Senior Member
 
Join Date: Jan 2009
Posts: 494
Pava is an unknown quantity at this point
...

Easy.ea in one of my posts...BS for buy...SS for sell
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
  #35 (permalink)  
Old 10-01-2009, 05:23 AM
Linuxser's Avatar
User Root
 
Join Date: May 2006
Location: Helliconia (Winter)
Posts: 4,410
Blog Entries: 56
Linuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond reputeLinuxser has a reputation beyond repute
Quote:
Originally Posted by xtream View Post
Image failed to upload on the start of thread. here it is
Something close on this thread. Look for kimiv 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
  #36 (permalink)  
Old 11-02-2009, 01:20 PM
Junior Member
 
Join Date: Oct 2009
Posts: 1
italiangoose is on a distinguished road
Smile Percent Trailing (Trailing stop)

Hi everyone,

I am busy working on a simple exit strategy, using a percent trailing. I have previously been working with Tradestation, but then discovered Metatrader and am currently developing an EA.

Tradestation has a function SetPercentTrailing where I can pass 2 values a floor amount and a percent trailing. I am trying to reconstruct this function in EA.

So far I have put together this code:

Code:
// Trailing stop calculation
   if(OrdersTotal() > 0)
      {
      OrderSelect(ticket, SELECT_BY_TICKET);
      CurrentProfit = OrderProfit();
      if (CurrentProfit >= HighestProfit)
         {
         HighestProfit = CurrentProfit;
         }
         
      if (HighestProfit >= (FloorAmt*Lots))
{
if ((HighestProfit - CurrentProfit) / HighestProfit) * 100 >= TrailingPct)
         {
            if(OrderType() == OP_BUY)
            {
               OrderClose(OrderTicket(),OrderLots(),Bid,Slippage,Red);
               HighestProfit = 0;
            }
            if(OrderType() == OP_SELL)
            {
               OrderClose(OrderTicket(),OrderLots(),Ask,Slippage,Red);
               HighestProfit = 0;
            }
            //Print("Closing order for Trailing amount");
         } }
      }
How it works, is that if I am in a trade, it continuasly sets a highest profit. Now if my current profit is higher then a floor amount that I set, and my profit drops below a certain percentage of my highest profit, then I close my trade.

Logically I think that this is correct, but unfortunately it does not give me the same results as in Tradestation, and I am wondering if there is an error in my code, or if Tradestation's Trailing Percent works differently.

Any help appreciated...thanks
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

Tags
metatrader trailing stop script, mql4 trailing stop, MT4 trailing stop script, pendind orders, profit target, script, trailing, trailing stop, trailing stop mq4, trailing stop mql, trailing stop script


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
ATR Trailing Stop - Help Boiseboy Indicators - Metatrader 4 59 11-06-2009 02:24 PM
Help Needed Making Perfect Trailing Stop EA sbwent Expert Advisors - Metatrader 4 31 08-07-2009 07:41 PM
Trailing Stop Script - Not EA iscuba11 Tools and utilities 3 07-02-2007 03:22 PM


All times are GMT. The time now is 01:16 PM.



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