Page 1 of 1

Fails to set attribute on one item.

Posted: Tue Jun 16, 2020 5:36 pm
by dmconsulting1
Here is the error message:

Setting attribute 'AccessibleValue' failed on element '{Row:PowerControlEnabled}'.
One of the identified items was in an invalid format.
Show/Hide Stacktrace
at Ranorex.Core.Element.SetAttributeValue(String name, Object value)at P38.Modules.Recipe_Functions.SetupTool.Ranorex.Core.Testing.ITestModule.Run() in C:\Work\Temp\P38.Ranorex\P38\Modules\Recipe Functions\SetupTool.cs:line 382at Ranorex.Core.Testing.TestModuleLeaf.RunInternal(DataContext parentDataContext, Int32 iteration, Int32 iterationCount, Boolean skipIteration)


I want to set the accessible value to False. Not sure why it has an issue with this one item in the UI. I attached a snapshot.

Here's the offending line item. It's actually a combobox, but it doesn't act like one. It's one of the great UI elements I get to work with on this project.

powerControlEnabled.rxsnp

Re: Fails to set attribute on one item.

Posted: Tue Jun 16, 2020 8:19 pm
by odklizec
Hi,

Apparently, Ranorex is not able to identify individual cells in this particular table. Just rows. And it's probably not enough to set its value? Additionally, SetValue is not 100% reliable solution when it comes to setting UI.

Have you tried another way of setting value to this particular row/element? For example, elements which act like combo box, can be often set by double click. What happens if you double click this row? Eventually, try to select the row (by mouse click) and then use spacebar or tab key to switch from true to false and vice versa. Anyway, using mouse action or keyboard shortcut is more appropriate way of setting UI than SetValue action, which often does not trigger mouse/keyboard related events.

Re: Fails to set attribute on one item.

Posted: Thu Jun 18, 2020 5:32 pm
by dmconsulting1
So currently I am clicking on the down arrow and selecting the item I want. What is interesting is the fact that Via Type, Processing Mode, Beam Positioner Mode and Accele Drill Type all work with SetValue and all are the same funky dropdown to select. Funky in that they don't appear as dropdowns unless you click on them.

The initial script was selecting the dropdown for each item, but then you have click on row, click on dropdown, click on item vs SetValue X. Granted, the first is a better representation of user action, but I am just trying to config my tooling parameters so I can run additional tests.

I just wanted o make sure it wasn't something stupid I was doing. :lol: