hey, i got the 10M chart code, but i need some help to add something to my refresh indicator code to activate the refresh on the 10m chart also...!
please help need it very badly!!
the row with the "case 10", just cant find anything to place there..
thank you for your time guys..!
please help need it very badly!!
the row with the "case 10", just cant find anything to place there..
thank you for your time guys..!
Inserted Code
#property copyright "coded by Christian Jungen" #property link "[email protected]" #property indicator_chart_window #include <WinUser32.mqh> extern string spr = "---Refresh Period---"; extern string spr1 = "M1=1, M5=5, M10=10, M15=15, M30=30"; extern string spr2 = "H1=60, H4=240, D1=1440, W1=10080"; extern int RefreshPeriod = 1; int hWindow = 0; int oldBars = 0; //+------------------------------------------------------------------+ //| indicator initialization function //+------------------------------------------------------------------+ int init() { hWindow = WindowHandle( Symbol(), Period() ); oldBars = iBars(NULL,RefreshPeriod); return (0); } //+------------------------------------------------------------------+ //| indicator start function //+------------------------------------------------------------------+ int start() { if ( oldBars < iBars(NULL,RefreshPeriod) && hWindow != 0 ) { int message; switch( Period() ) { case 1: message = 33137; break; case 5: message = 33138; break; //---------------------------------------------- case 10: message = **WHAT NUMBER DO I NEED TO ENTER HERE TO DO THAT?**; //??? 10M break; //---------------------------------------------- case 15: message = 33139; break; case 30: message = 33140; break; case 60: message = 33135; break; case 240: message = 33136; break; case 1440: message = 33134; break; case 10080: message = 33141; break; default: message = 33140; // m30, if we can't identify current TF break; } PostMessageA( hWindow, WM_COMMAND, 33140, 0 ); // switch to weekly TF PostMessageA( hWindow, WM_COMMAND, message, 0 ); // switch to original TF oldBars = iBars(NULL,RefreshPeriod); } return (0); }