0

I have a slider, and if I get sliders()[0].value(), it returns a totally wrong value.
I'm thinking something has to do with Value Indicator. However, valueIndicator doesn't show up in sliders()[0].uiElements() or .entireContents().
How can I obtain the correct value of the slider? If you have to use value indicator, how do you obtain it using the value indicator with JavaScript?
Thanks!

Danny Buonocore
  • 3,731
  • 3
  • 24
  • 46
jl303
  • 1,461
  • 15
  • 27
  • Some code would be nice – Danny Buonocore Aug 11 '16 at 20:32
  • I'm just getting regular slider from an ObjectSpecifier. I found that if I do sliders[0].attributes[2].value(), then I get the right value. sliders[0].attributes[2].name() is AXValueDescription. However, I can't do sliders[0].valueDescription(). Is there way to obtain the value without accessing the attributes array? – jl303 Aug 11 '16 at 21:17

1 Answers1

0

I opened the Accessibility Inspector from xCode and looked at the slider that is causing the problem. The accessibility inspector showed all the attributes of the slider, and I found out that the slider.attributes["AXValueDescription"} had the right value.

jl303
  • 1,461
  • 15
  • 27