Errors, bugs, questions - page 1743

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
How can the debugger see what value the function returned via return? I put a breakpoint on return. When I get to it, I press F10. How do I see what's in return?
But since apparently everything in your code is built on classes, you can expect about a dozen angry letters explaining how Meta Editore is horrible, bad and inconvenient with debugging))
{
public:
void operator =( const string Value ) const { return; }
void operator =( const int Value ) { return; }
};
void OnStart()
{
const A a;
a = 0; // implicit conversion from 'number' to 'string'
}
shift + F9 ('add watch')
If it does not return anywhere, or if there are several nested calls, create a variable so that the result of the function can be written there and debugged.
The variable in which the function casts the value.
If it doesn't return anywhere, or has several nested calls, create a variable so that you can write the result of the function there and debug it.
Well, every clever person can do it with a variable. But I have to, like a fool - without it.
There are a lot of functions like this.
{
return(::ChartSetInteger(this.chartID, id, Value));
}
virtual bool SetProperty( const ENUM_CHART_PROPERTY_DOUBLE id, const double Value ) const
{
return(::ChartSetDouble(this.chartID, id, Value));
}
virtual long GetProperty( const ENUM_CHART_PROPERTY_INTEGER Property, const int SubWindow = 0 ) const
{
return(::ChartGetInteger(this.chartID, Property, SubWindow));
}
virtual double GetProperty( const ENUM_CHART_PROPERTY_DOUBLE Property, const int SubWindow = 0 ) const
{
return(::ChartGetDouble(this.chartID, Property, SubWindow));
}
And now you have to insert a variable into each of them? Is there any other way?
And now insert a variable into each one? Is there any other way?
Obviously these functions must be renamed: GetPropertyLong, GetPropertyDbl. Why do they have the same name?
In the future, the developers promised to modify function templates to be able to call them in the following way: GetProperty<long>(...) But you won't make a template virtual.
Obviously these functions should be renamed: GetPropertyLong, GetPropertyDbl. Why do they have the same name?
I don't understand why they have different names. I use this one.
this.SetProperty(OBJPROP_YSIZE, (int)CHARTOBJECT::GetProperty(CHART_HEIGHT_IN_PIXELS)); // Ширина объекта по оси Y в пикселях
this.SetProperty(OBJPROP_DATE_SCALE, false); // Признак отображения шкалы времени для объекта "График"
this.SetProperty(OBJPROP_BACK, false); // Объект на заднем плане
this.SetProperty(CHART_AUTOSCROLL, false); // Режим автоматического перехода к правому краю графика
this.SetProperty(CHART_SHIFT, false); // Режим отступа ценового графика от правого края
this.SetProperty(CHART_SHOW_OHLC, false); // Отображение в левом верхнем углу значений OHLC
this.SetProperty(CHART_SHOW_PERIOD_SEP, false); // Отображение вертикальных разделителей между соседними периодами
this.SetProperty(CHART_SHOW_VOLUMES, CHART_VOLUME_HIDE); // Отображение объемов на графике
this.SetProperty(CHART_SHOW_TRADE_LEVELS, false); // Отображение на графике торговых уровней (уровни открытых позиций, Stop Loss, Take Profit и отложенных ордеров)
this.SetProperty(CHART_MODE, CHART_LINE); // Тип графика (свечи, бары или линия)
this.SetProperty(CHART_COLOR_CHART_LINE, clrNONE); // Цвет линии графика и японских свечей "Доджи"
this.SetProperty(CHART_SCALEFIX, true); // Цвет линии графика и японских свечей "Доджи"
this.SetProperty(CHART_FIXED_MAX, 1.5); // Фиксированный максимум графика
this.SetProperty(CHART_FIXED_MIN, 1.0); // Фиксированный минимум графика
In the future, the developers promised to modify function templates so that they could call this way: GetProperty<long>(...) But you can't make a template virtual.
I don't understand the example.
I would be glad to listen to your (and other competent forum users') critics (in all seriousness) on architectural stylistics and programmer's tone to my code. I'll post it in kodobase, as soon as I finish it. It's never a shame to learn.
MT4 Build 1010 (19 Aug 2016)