- Search Crypto Craft
-
Beerrun replied Nov 4, 2019You need to share more of your code
I will code your EAs and Indicators for no charge
-
Beerrun replied Oct 27, 2019Maybe this line: for(int i=total-1; i>=0; i--) if(m_position.SelectByIndex(k)) Should k be changed to i? Something like this: double Hi=iHigh(NULL,43200,iHighest(NULL,43200,MODE_HIGH,WHOLE_ARRAY,0)); double ...
I will code your EAs and Indicators for no charge
-
Beerrun replied Oct 27, 2019This is incorrect. A static variable inside a function retains its value between function calls, the first declaration with a value assignment gives it an initialized value. A static variable behaves exactly like a global variable but with scope ...
I will code your EAs and Indicators for no charge
-
Beerrun replied Oct 26, 2019No, the last parameter is the bar index number, an integer, starting from the current bar 0 and going to the left, you can’t put a date unless you first wrap the date in an iBarShift() call.
I will code your EAs and Indicators for no charge
-
Beerrun replied Oct 25, 2019No problem. Also make sure you reset the button state after each click, either true (down) or false (up)
Dropdown menu in MQ4
-
Beerrun replied Oct 25, 2019Just drawing like you would a rectangle and then void OnChartEvent(const int id,const long& lparam,const double& dparam,const string& sparam){ if(CHARTEVENT_OBJECT_CLICK){ if(sparam==“your button name”){ if(yourbuttonstate){} if(!yourbuttonstate){} ...
Dropdown menu in MQ4
-
Beerrun replied Oct 25, 2019The ‘v’ is a button graphical object, and uses OnChartEvent to read mouse interaction. When it is clicked and the state is true then the rest of the dashboard is drawn, most likely using multiple functions. Here is the mql4 doc for button object ...
Dropdown menu in MQ4
-
Beerrun replied Oct 24, 2019Newbar code: int start(){ //...your every tick (not bar dependent) code here... datetime new=iTime(NULL,0,0); //or Time[0] static datetime newbar=iTime(NULL,0,0); if(newbar>=new)return 0; else newbar=new; //...your new bar dependent code here... ...
I will code your EAs and Indicators for no charge
-
Beerrun replied Oct 11, 2019Just old and new mql4 changes, both work for what you want. But Bars(...) also has a 2nd version that allows start and end dates
Fixing an Array out of range error in MT4 EA
-
Beerrun replied Oct 11, 2019I was thinking something like this for(int i=(IndicatorCounted()==0)?Bars(symbol,tf)-1-MathMax(IntInd1S2,IntInd1S1+1):1;i>0;i—){ int hi=iHighest(symbol,tf,mode,IntInd1S2,i); if(hi!=-1)PerH1=High[hi]; else PerH1=-1; int lo=iLowest(...); ...
Fixing an Array out of range error in MT4 EA
-
Beerrun replied Oct 11, 2019Can try this one url
Looking for Trailing Stop EA like default MT4 trailing stop
-
Beerrun replied Oct 11, 2019Don’t forget the (-1) to convert from size to position BarCount1=LimitBars1-1 and make sure iLowest/iHighest is not returning -1
Fixing an Array out of range error in MT4 EA
-
Beerrun replied Oct 10, 2019Perhaps use the Bars() function which takes the symbol and timeframe as parameters, instead of the Bars variable which is limited to the current chart symbol and timeframe. An extra thing to consider is if iLowest/Highest returns an error, you’d be ...
Fixing an Array out of range error in MT4 EA
-
Beerrun replied Oct 10, 2019Yeah it should work. If not then create a variable to keep a running count. Otherwise it is going to run the loop for every bar on every tick.
Fixing an Array out of range error in MT4 EA
-
Beerrun replied Oct 10, 2019Try fixing your for loop first, in the second code block, the loop never runs so no errors could happen: i=0 but checks i>Bars. With i decrementing should be: for(int i=Bars-IndicatorCounted()-1;i>0;i—)
Fixing an Array out of range error in MT4 EA
-
Beerrun replied Oct 7, 2019Perhaps someone in this thread might know, I don’t have much knowledge of specific indicators
I will code your EAs and Indicators for no charge
-
Beerrun replied Oct 7, 2019Its because the author of the program has the lookback loop checking the current bar, i=0. Change it to i=1
I will code your EAs and Indicators for no charge
-
Beerrun replied Oct 7, 2019Points To BE -how many points in profit before the stop is moved to breakeven. BE+ In Points -how many points over breakeven you want the stop moved when breakeven occurs. Points To Begin Trail After BE -how many more additional points in profit ...
Can someone check and test this Trade Manager EA for me?
-
Beerrun replied Oct 7, 2019This post is the most recent, let me know if any errors
Can someone check and test this Trade Manager EA for me?
-
Beerrun replied Oct 7, 2019I'm sorry buddy but I have zero experience in MT5
Can someone check and test this Trade Manager EA for me?