How can I know CChartObjectTrend 's angle?

 
I create CChartObjectTrend by code, How can I know CChartObjectTrend 's angle?
 
What do you mean by "angle"? And how do you plan to use it? Do you understand that the angle you see on the chart between trend line and horizontal line depends on such things as vertical scale and horizontal zoom levels?
Documentation on MQL5: Standard Constants, Enumerations and Structures / Objects Constants / Object Types
Documentation on MQL5: Standard Constants, Enumerations and Structures / Objects Constants / Object Types
  • www.mql5.com
Standard Constants, Enumerations and Structures / Objects Constants / Object Types - Documentation on MQL5
 
codeidea:
I create CChartObjectTrend by code, How can I know CChartObjectTrend 's angle?

From documentation :

Properties

 

Angle

Gets/Sets property "Angle"

 
Angle one for this class: CChartObjectTrendByAngle , I use class CChartObjectTrend
Documentation on MQL5: Standard Library / Classes for Graphic Objects / Objects Lines / CChartObjectTrendByAngle
Documentation on MQL5: Standard Library / Classes for Graphic Objects / Objects Lines / CChartObjectTrendByAngle
  • www.mql5.com
Standard Library / Classes for Graphic Objects / Objects Lines / CChartObjectTrendByAngle - Documentation on MQL5
 
codeidea:
Angle one for this class: CChartObjectTrendByAngle , I use class CChartObjectTrend
And why not use the first one if you need to work with angle ?
 
angevoyageur:
And why not use the first one if you need to work with angle ?
only know the price and time to create CChartObjectTrend, I need the angle as result
 
codeidea:
only know the price and time to create CChartObjectTrend, I need the angle as result
For the last time, please read the documentation and try it, you have to use CChartObjectTrendByAngle !
 

I have got it:

atan((price1-price2)/Bars(time1 to time2))

Reason: