Disliked...for 1 Line how many pips and (additional if you can) how many candles...Ignored
Attached File(s)
Rectangle_Ruler_bars_durations_pips_ranges_v1.2.ex4
51 KB
|
299 downloads
4
I will code your pivot EAs for no charge 23 replies
I will code your scalping EAs for no charge 163 replies
Oanda MT4 - Indicators and EAs not showing 2 replies
EAs and indicators relating to moutaki... 22 replies
InterbankFX has loaded its MT4 platform with custom EAs, indicators and scripts 1 reply
Disliked...for 1 Line how many pips and (additional if you can) how many candles...Ignored
DislikedHello Everyone, I have reached here as I thought it was the most appropriate place to post this. I have put together an EA using some ideas and codes taken here and there that simply perform some actions for manual trading via buttons. I am to the point I don't really know how to improve it, it is not performing well for some reasons (most likely badly coded by myself). Is anyone able to help fix it? ...or maybe point me out to where I could post for help? Thank you {image} {file}Ignored
void OnTick() { RefreshRates(); // Spread Text double spread = (Ask - Bid) / Point; ObjectSetText("ButtonEA-Spread_00_Label", StringSubstr(Symbol(),0,3)+"/"+StringSubstr(Symbol(),3,3)+ " Spr " + DoubleToStr(NormalizeDouble(spread / divider, 1), SpreadDigits) + " pt", add_text_size+1, sFontType, clrOlive); // Profit Text //start(); // if(Bars<100 || IsTradeAllowed() == false) return; if(CalculateCurrentOrders()!= 0) SetSLnTP(); }
Disliked{quote} hi jean would you please consider same option for rectangle box filled /unfiled (draw object back ground on/off) and show as all toolbox on chart straight trendline and rectanglebox please. i use 2 indicator if possible combine any coder in one toolbox please.(atached image {file} {file} {image} {image}Ignored
Disliked{quote} It's not a line, but functionally the same. {file} {image}Ignored
Disliked{quote} hi jean would you please consider same option for rectangle box filled /unfiled (draw object back ground on/off) and show as all toolbox on chart straight trendline and rectanglebox please. i use 2 indicator if possible combine any coder in one toolbox please.(atached image {file} {file} {image} {image}Ignored
DislikedHey Guys, i want to learn and improve my MQL4 skills. I think the best way to do this is to practice. Unfortunately sometimes I don`t have any nice idea which i can implement in a Expert Advisor / Indicator. So if any of you is interested, please post in this forum your ideas and i will try to implement it into mql4. AndiIgnored
DislikedHello All. Does anyone recognise this indicator in the lower window or have anything similar. It is idea for giving current direction bias for both trading generally and is great for EA's. I will need a MQ4 version. {image}Ignored
Disliked{quote} void OnTick() { RefreshRates(); // Spread Text double spread = (Ask - Bid) / Point; ObjectSetText("ButtonEA-Spread_00_Label", StringSubstr(Symbol(),0,3)+"/"+StringSubstr(Symbol(),3,3)+ " Spr " + DoubleToStr(NormalizeDouble(spread / divider, 1), SpreadDigits) + " pt", add_text_size+1, sFontType, clrOlive); // Profit Text //start(); // if(Bars<100 || IsTradeAllowed() == false) return; if(CalculateCurrentOrders()!= 0) SetSLnTP(); } Pardon me as I didn't have time to look in detail, but I notice this part of the code is executing on every tick....Ignored
int OnInit() { EventSetTimer(1); } void OnDeinit() { EventKillTimer(); } void OnTimer() {if(CalculateCurrentOrders()!= 0) SetSLnTP(); }
int Buy_000000_Button(const string sparam) { //Get new market prices RefreshRates(); double Spread = Ask - Bid; if(Spread>MaxSpreadPoints*bPip) {Alert("Spread to high: " ,GetLastError()); return(false);} //Define lot size double Lot_Extract = StrToDouble(ObjectGetString(0, "ButtonEA-Lot_00000_Edit", OBJPROP_TEXT, 0)); int TakeProfitPoints = StrToDouble(ObjectGetString(0, "ButtonEA-Take_Prof_Edit", OBJPROP_TEXT, 0)); int StopLossPoints = StrToDouble(ObjectGetString(0, "ButtonEA-Stop_Loss_Edit", OBJPROP_TEXT, 0)); double TakeProfit = 0, StopLoss = 0; //Normalize the digits and calculate the position size double nTickValue = MarketInfo(Symbol(),MODE_TICKVALUE); if(Digits == 3 || Digits == 5) {SlippagePoints = SlippagePoints*10; nTickValue = nTickValue*10;} if(Digits == 2) {SlippagePoints = SlippagePoints*100; nTickValue = nTickValue*100;} double PipValuePerLot = (nTickValue/MarketInfo(Symbol(), MODE_TICKSIZE))*bPoint; double SpreadValue = MarketInfo(Symbol(),MODE_SPREAD)*PipValuePerLot; //Define TakeProfit and StopLoss levels if(TakeProfitPoints>0) TakeProfit = NormalizeDouble(Bid+Spread+(TakeProfitPoints*bPoint),Digits); if(StopLossPoints>0) StopLoss = NormalizeDouble(Bid+Spread-(StopLossPoints*bPoint),Digits); if(Lot_Extract == 0){ //Lot_Extract = (AccountBalance()*RiskPercentage/350)/(StopLossPoints*nTickValue); //Lot_Extract = MathRound(Lot_Extract/MarketInfo(Symbol(),MODE_LOTSTEP))*MarketInfo(Symbol(),MODE_LOTSTEP); Lot_Extract = NormalizeDouble(LotSize(),2); } // Comment: string text = StringConcatenate(" Pt",NormalizeDouble(((SpreadValue*2)+(CommissionValue*Lot_Extract))/(PipValuePerLot*Lot_Extract),0)," Cost£",NormalizeDouble((SpreadValue*2)+(CommissionValue*Lot_Extract),2)," 1P£",PipValuePerLot*Lot_Extract); // Send Order int Ticket = OrderSend(Symbol(),OP_BUY,NormalizeDouble(Lot_Extract,2),Ask,SlippagePoints,StopLoss,TakeProfit,text,Magic,0,clrNONE); if(Ticket == -1) {Alert("Buy Error: " ,GetLastError()); return(false);} if(Ticket>=0) {return(true); } return(0); } double LotSize() { double Lot, Lots=0.01; double LotOptimized; double lotstep; double marginrequired; if (RiskPercentage > 0 ) { lotstep = MarketInfo(Symbol(), MODE_LOTSTEP); marginrequired = MarketInfo(Symbol(), MODE_MARGINREQUIRED); Lot = AccountBalance() * RiskPercentage / 100.0 / marginrequired; LotOptimized = MathMod(Lot, lotstep); if (LotOptimized != 0.0) Lot -= LotOptimized; } else Lot = Lots; double minlot = MarketInfo(Symbol(), MODE_MINLOT); double maxlot = MarketInfo(Symbol(), MODE_MAXLOT); if (Lot < minlot) Lot = minlot; if (Lot > maxlot) Lot = maxlot; return (Lot);
Dislikedplease tell me which color is correct? red sell or green buy? and plz someone could add on and off button to this indcator ,thanks {image} {file}Ignored
Disliked{quote} resembles macd or blau tvi perhaps look at v2v in search bar to me it looks more like blau tvi i also recall i belive that will tools in his jurick thread on hear posted something very similar at some point on his thread v2v proberly your best bet for finding similar as he also had a button where he had linear regresional and standard linear regression again resemble my bet one of those three would be very similar however yours seems to have a 3rd colour which resembles a disagrence i look for between the macd osma mark zones like this in...Ignored
Disliked{quote} Well, still went ahead and made a line option. {file} {image}Ignored
Disliked{quote} Thank you eess for pointing that out, I have just checked out the OnTime function and I have added the below elements in the appropriate places. int OnInit() { EventSetTimer(1); } void OnDeinit() { EventKillTimer(); } void OnTimer() {if(CalculateCurrentOrders()!= 0) SetSLnTP(); } In regards to the lot calculation, if the lot text is set to 0.00, it is supposed to auto calculate the lot size based on the risk setting, however, it seem to have issues calculating the lot as sometimes I am getting an invalid lot error. Here is the code for the...Ignored
void OnTick() { RefreshRates(); // Spread Text double spread = (Ask - Bid) / Point; ObjectSetText("ButtonEA-Spread_00_Label", StringSubstr(Symbol(),0,3)+"/"+StringSubstr(Symbol(),3,3)+ " Spr " + DoubleToStr(NormalizeDouble(spread / divider, 1), SpreadDigits) + " pt", add_text_size+1, sFontType, clrOlive);
Disliked{quote} Hi, I am not able to reproduce the error you mentioned about the lotsize. So far I check through the function LotSize() in your code, it is returning the correct value. Not sure if the error you mentioned is exceptional cases....if yes, I'm afraid it would be difficult to reproduce on my side. Regarding performance issue, when the market opens tomorrow, you can run your EA to see if it is still lagging, if it is, you may need to see whether it is needed to move this part of the code to the onTimer function as well because I'm not sure if...Ignored
// Broker digits if(Digits == 2 ) {bPoint = 0.01; bPip = 0.10;} else if(Digits == 3 ) {bPoint = 0.001; bPip = 0.010;} else if(Digits == 5 ) {bPoint = 0.00001; bPip = 0.00010;};
if(StringSubstr(Symbol(),0,7)=="Bitcoin") bPoint=10;