I have written an indicator that reads drawnobjects and if it is an Andrews Pitchfork, I then use it's 3 anchor points, which is working well. When I try to get the color, It returns some Blue color, which is not even the default Blue. Below is where I set up my structure, and then
// This is where I loop through all drawn obects to locate each Andrew Pitchfork that was manually drawn
foreach (IDrawObject draw in DrawObjects)
{
// Determinite if selected object is an Andrews Pitchfoirk
if (draw.UserDrawn && draw.DrawType == DrawType.AndrewsPitchfork )
{
// and when found I then get amd save to variables the bars ago and price values of the 3 points
// Then I use the 3 points in the calculations and drawing of the DGLs
pitchfork = (IAndrewsPitchfork) draw ;
Then here is the line I Draw a line on trying to use the color of the pitchfork that does not do what I want. I have also attached a screen shot of the watch variable structure pointing to the field that has what I want.
DrawLine("JOR"+JOR_Line_Cnt.ToString(), false, pitchfork.Anchor1BarsAgo, JOR_Anchor_Price1, JOR_Draw_End_Bar, JOR_Tmp_Price, pitchfork.Pen.Color, DashStyle.Solid, 2);
I did try using the editor "intellisense" to assist finishing my variable, "pitchfork." but I only saw the fields listed in the help manual, with only Pen,Color
As always - your help is appreciated.
John
Comment