Can someone please explain when converting from generated code to custom user code, this FindAdapter code gets created? I don't understand the FindAdapter logic and why the generated code does not convert into the User Code. Am I possibly missing a Ranorex option that needs to be set?
See Example:
Report.Log(ReportLevel.Info, "Keyboard", "Key sequence from variable '$varEndDate' with focus
on 'comboboxInfo'.", repo.AuthorizationForm.TreatmentLine.EndDateccbInfo);
AuthEndDate.FindAdapter<ComboBox>().PressKeys(varEndDate);
FindAdapter Definition
Re: FindAdapter Definition
Hi,
This has been changed in Ranorex 6.2. Basically, if the action is converted to User Code, repo item used in the action is converted to repoiteminfo argument. And because PressKeys, Click and many other methods requires an adapter, Ranorex automatically converts the repoiteminfo to adapter, using FindAdapter method. This feature was discussed also here:
https://www.ranorex.com/forum/merge-act ... tml#p41899
There is no option to change this behavior. If you don't like this automatic behavior, you only hope is to create the custom method manually (without repoiteminfo argument) and copy the action code from recording.cs file.
This has been changed in Ranorex 6.2. Basically, if the action is converted to User Code, repo item used in the action is converted to repoiteminfo argument. And because PressKeys, Click and many other methods requires an adapter, Ranorex automatically converts the repoiteminfo to adapter, using FindAdapter method. This feature was discussed also here:
https://www.ranorex.com/forum/merge-act ... tml#p41899
There is no option to change this behavior. If you don't like this automatic behavior, you only hope is to create the custom method manually (without repoiteminfo argument) and copy the action code from recording.cs file.
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration