Because of this
ObjectSetInteger(0,"Harmonic Point",OBJPROP_CORNER,CORNER_RIGHT_UPPER);
Because of this
I was just coming here to update this because I figured that out. How do I fix it without changing where the initial dot is drawn? I tried resetting the OBJPROP_CORNER after the dot has been drawn, but it doesn't make any difference.
This is where the red dot needs to draw, so it needs to be right-aligned initially.
I was just coming here to update this because I figured that out. How do I fix it without changing where the initial dot is drawn? I tried resetting the OBJPROP_CORNER after the dot has been drawn, but it doesn't make any difference.
This is where the red dot needs to draw, so it needs to be right-aligned initially.
Seeing your screenshot I don't even understand why you need to convert from X/Y to Time/Price, but anyway :
int width=(int)ChartGetInteger(0,CHART_WIDTH_IN_PIXELS,0); ChartXYToTimePrice(0,width-HAX,HAY,HA_Win,HA_Time,HA_Price);
Seeing your screenshot I don't even understand why you need to convert from X/Y to Time/Price, but anyway :
I'm highlighting the highs and lows, inputting them into an array and using it to search for patterns. Thanks very much!!
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello everyone,
I am having issues with the function ChartXYToTimePrice. It is returning the correct price, but it always returns the incorrect time. I have written a script that creates a little red dot at the side of the chart that you move onto the chart and click a button. Once you click a button it's supposed to get the XY coordinates of the dot, replace it with a green one, and then convert the XY coordinates to Time and Price data that I will later do other things with. Here is the code.
Everything above the /// line seems to work, however the ChartXYToTimePrice consistently returns an incorrect value. Here is a screenshot of the error.
As you can see the green dot places at the correct XY coordinates, but then when they are converted to Time/Price data the time line places in the wrong place. Any idea why?
Regards,
Nik