Hi,
We are working with Ranorex 3.2.3.16825 on Windows 8 Consumer Preview 64bit version,and current user is a member of Administrators group.
We met a very thorny issue about Windows8 Metro UI and Charms bar.
We can recognize some objects by Ranorex Spy in Metro/Charms bar,also can record the scripts by Ranorex Recorder, but the recorded scripts cannot replay successfully. Always met the "No element found for path" even it's just be recorded by the tool
For example,I did very simple record - press windows key to go to Metro start screen,then cick desktop icon on the metro screen to go back to desktop. Also tried to use spy to replace the xpath with spied result, still doesn't work.
Ranorex can not recognize the element of Desktop item in Metro,the error message as blow:
Failed to find item 'sampleRepository.ContainerStart_menu.ListItemDesktop'. The folder 'sampleRepository.ContainerStart_menu' was not found. No element found for path '/container[@automationid='Start menu window']' within 30s.
Show/Hide Stacktrace
at Ranorex.Core.Repository.RepoItemInfo.Find[T](Boolean findSingle, Boolean throwException) at Ranorex.Core.Repository.RepoItemInfo.CreateAdapter[T](Boolean throwException) at sample.sampleRepositoryFolders.ContainerStart_menuAppFolder.get_ListItemDesktop() in c:\Users\admin\Documents\Ranorex\RanorexStudio Projects\sample\sample\sampleRepository.cs:line 119 at sample.Recording1.Ranorex.Core.Testing.ITestModule.Run() in c:\Users\admin\Documents\Ranorex\RanorexStudio Projects\sample\sample\Recording1.cs:line 85 at Ranorex.Core.Testing.TestSuiteModule.RunInternal(DataContext parentDataContext)
Would you give some suggestion or solution on this problem? Many thanks in advance.
Can't recognize win8 metro element when replay scripts
Can't recognize win8 metro element when replay scripts
You do not have the required permissions to view the files attached to this post.
Think Different!
Re: Can't recognize win8 metro element when replay scripts
I would like to add a little explanation, although UAC(User Account Control) is turn off,the recorded scripts cannot replay successfully also
You do not have the required permissions to view the files attached to this post.
Think Different!
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Can't recognize win8 metro element when replay scripts
Currently, you have to explicitly start the Ranorex Tool as Administrator; i.e. right click on Ranorex Recorder (or Spy, Studio) and select "Run as administrator". Then the replay should work.
The problem is that automating the Window 8 Metro UI requires special privileges. The Ranorex Tools (Spy, Recorder, Studio) already acquire this privilege; that's why Tracking and Recording works, but the replay is done by a separate process and that process only inherits the privilege if the parent process (Ranorex Tool) is explicitly started as Administrator.
We will try to facilitate automating the Metro UI for the Windows 8 RTM.
Regards,
Alex
Ranorex Team
The problem is that automating the Window 8 Metro UI requires special privileges. The Ranorex Tools (Spy, Recorder, Studio) already acquire this privilege; that's why Tracking and Recording works, but the replay is done by a separate process and that process only inherits the privilege if the parent process (Ranorex Tool) is explicitly started as Administrator.
We will try to facilitate automating the Metro UI for the Windows 8 RTM.
Regards,
Alex
Ranorex Team
Re: Can't recognize win8 metro element when replay scripts
Alex,thanks very much for your kindly reply.Support Team wrote:Currently, you have to explicitly start the Ranorex Tool as Administrator; i.e. right click on Ranorex Recorder (or Spy, Studio) and select "Run as administrator". Then the replay should work.
The problem is that automating the Window 8 Metro UI requires special privileges. The Ranorex Tools (Spy, Recorder, Studio) already acquire this privilege; that's why Tracking and Recording works, but the replay is done by a separate process and that process only inherits the privilege if the parent process (Ranorex Tool) is explicitly started as Administrator.
We will try to facilitate automating the Metro UI for the Windows 8 RTM.
Regards,
Alex
Ranorex Team
Yes,once right click on Ranorex Recorder,and select "Run as administrator",the replay works.
However,when we use the same way to execute the build file(i.e. ..\bin\Debug\sample.exe),right click on sample.exe,and select "Run as administrator",it doesn't work, still met the "No element found for path" error when replay metro element
Could your tell me how to fix that? Because we need to invoke the ranorex compiled executive file directly,not by Ranorex Recorder or Ranorex Studio.
Moreover,right click on executive file and select "Run as administrator" is a manual action,
is there any method or command to invoke application as administrator directly?
Think Different!
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Can't recognize win8 metro element when replay scripts
Hi,
That's because the exe is not in a trusted location and not signed.
As current workaround you can also use the TestSuiteRunner, but take in account that you also have to open it as administrator, it is located in the bin directory of Ranorex.
As Alex wrote we will try to improve support for Metro in one of the future releases.
Regards,
Markus
Ranorex Support Team
That's because the exe is not in a trusted location and not signed.
As current workaround you can also use the TestSuiteRunner, but take in account that you also have to open it as administrator, it is located in the bin directory of Ranorex.
As Alex wrote we will try to improve support for Metro in one of the future releases.
Regards,
Markus
Ranorex Support Team
-
- Posts: 1
- Joined: Tue Dec 11, 2012 9:22 am
Re: Can't recognize win8 metro element when replay scripts
Hi,
Can TestSuiter Runner be invoke through command?
Otherwise it cannot resolve our issue.
We need invoke testsuite.exe through command.
When will testsuite.exe be invoked successfully for win8 metro testing?
Is there any plan to reslove it? and when?
Thanks very much.
Can TestSuiter Runner be invoke through command?
Otherwise it cannot resolve our issue.
We need invoke testsuite.exe through command.
When will testsuite.exe be invoked successfully for win8 metro testing?
Is there any plan to reslove it? and when?
Thanks very much.
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Can't recognize win8 metro element when replay scripts
Hi,
You can use the UiaLauncher in order to start your test executable via command line.
UiaLauncher (<Ranorex Installation Folder>\bin\Ranorex.UiaLauncher32.exe), you have to pass the executable name as the first argument.
For more details please take a look at the following forum posts: How to run testsuite against win8 metro app by command line, Windows 8 Metro app via Ranorex C#.
Regards,
Markus
You can use the UiaLauncher in order to start your test executable via command line.
UiaLauncher (<Ranorex Installation Folder>\bin\Ranorex.UiaLauncher32.exe), you have to pass the executable name as the first argument.
For more details please take a look at the following forum posts: How to run testsuite against win8 metro app by command line, Windows 8 Metro app via Ranorex C#.
Regards,
Markus