Skip to content

Commit

Permalink
Updated for RangeBars ver. 3.01
Browse files Browse the repository at this point in the history
  • Loading branch information
9nix6 committed Feb 23, 2020
1 parent e6121f7 commit 0d51499
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
11 changes: 6 additions & 5 deletions Include/AZ-INVEST/SDK/RangeBars.mqh
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,6 @@ int RangeBars::Init()
s.atrPercentage,
s.showNumberOfDays, s.resetOpenOnNewTradingDay,
TradingSessionTime,
TopBottomPaddingPercentage,
showPivots,
pivotPointCalculationType,
RColor,
Expand All @@ -203,11 +202,8 @@ int RangeBars::Init()
PDHColor,
PDLColor,
PDCColor,
showCurrentBarOpenTime,
AlertMeWhen,
AlertNotificationType,
SoundFileBull,
SoundFileBear,
cis.MA1on,
cis.MA1lineType,
cis.MA1period,
Expand Down Expand Up @@ -245,7 +241,12 @@ int RangeBars::Init()
cis.ChannelPriceLabel,
cis.ChannelMidPriceLabel,
true); // used in EA
// DisplayAsBarChart & ShiftObj let at defaults
// TopBottomPaddingPercentage,
// showCurrentBarOpenTime,
// SoundFileBull,
// SoundFileBear,
// DisplayAsBarChart
// ShiftObj; all letft at defaults

if(rangeBarsHandle == INVALID_HANDLE)
{
Expand Down
3 changes: 3 additions & 0 deletions Indicators/RangeBars/RangeBars_TimeLine.mq5
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,9 @@ string NormalizeTime(datetime _dt)
string minute = (dt.min<10) ? ("0"+(string)dt.min) : (string)dt.min;
string hour = (dt.hour<10) ? ("0"+(string)dt.hour) : (string)dt.hour;

if((dt.mon-1) < 0 || (dt.mon-1) > 11)
return "*";

if(InpDispFormat == DisplayFormat1)
return ( "'"+(string)dt.day+" "+__months[dt.mon-1]+" "+hour+":"+minute );
else
Expand Down

0 comments on commit 0d51499

Please sign in to comment.