How To identify Object After Navigation in Coded UI - coded-ui-tests

i m new to MS Coded UI Automating, my Question is.
When i launch my Browser (IE) and fill the detials and then click on submit button. it takes me to new page where i get an error called action cannot be perform on hidden objects
i am using MS 2012 Premium Verison
thanks

Limited information to go on, but have you checked out this the fallowing?
http://blogs.msdn.com/b/visualstudioalm/archive/2013/09/17/coded-ui-mtm-issues-on-internet-explorer-with-kb2870699.aspx
Coded UI error: The following element is not longer availabe
This might be the annoying side effect of Windows Update KB2870699, update 4 for VS2012 is supposed to fix this but an alternative work around is simply to uninstall this update.

Related

Copying and Renaming xhtml file to new file in JSF causing data does not load

I received an assignment to have a look at Java Server Faces project and maintain the existing code if possible. My background is ASP.net , and never made a Java program previously. The problem is like this : there is existing file code named policy_list.xhtml (with also several beans attached to UI component in the file) and lets say it attach to menu Policy List. If user click the menu, the policy_list.xhtml will show the list of Policy. I copied the policy_list.xhtml file and renamed it to a new file renewal_list.xhtml. And I created a new menu Renewal List and attach the link to renewal_list.xhtml. I did not make any changes to renewal_list.xhtml. However , when I click the Renewal List menu, the page did not show any data like the Policy List menu. There is no error shown in the page What is wrong with the Renewal List page. Is it the behaviour of JSF ? On the IntelliJ IDEA debugger, I have not found any error. However the Search button in the renewal_list.xhtml working fine just as policy_list.xhtml. All the action link in the dataTable does not work in renewal_list.xhtml. I guess I am missing as particular setup on the menu or else ? Any ideas ?
My God, I have to registered it on pages.xml . Now, its working. Thanks to the powerful search of IntelliJ idea.

CodedUI Visual Studio: How to wait for browser load

I was wondering if anyone new how to make the Automation Script in CodedUI wait for the web page to load before continuing on with the script.
So I fill out a form and press the "Continue" button, then the script times out because it gives up waiting. I realise I could use Playback.wait but then I would have code this each time I click continue.... and I have hundreds of scripts! Something similar to Seleniums WaitforBrowserLoad but for CodedUI
C# CodedUI in VS 2012
Any help would be appreciated.
In my experience, Coded UI is excellent about waiting for page loads to be complete before continuing test execution. That said, you can force a wait for a specific control to exist with WaitForControlExist method. This method is a member of the base class of all UI controls, UITestControl.
You could also use:
Playback.PlaybackSettings.WaitForReadyLevel = WaitForReadyLevel.AllThreads;
Sounds like your issue could be fixed if you create a settings file and increase the timeout.
Directions Here: Specifying Test Settings in Visual Studio
You could also call the WaitForControlReady method on the browser window object.
ex:
_browserWindow.WaitForControlReady(60000); //Should wait for 1 min

Issue after editing Search Properties in coded UI?

We are using coded ui test using visual studio 2010.We are testing .Net 4.0 windows application.
Here is an scenario.
We have an windows app which has a button named submit and we have recorded a workflow which clicks on submit.
Now when we generate code using coded ui the serach criteria for the button is based on its name (display name of button).
If tommorrow developer changes the button's text to submit1 , our scripts fail.
We tried using "controlName"[name given to the control and not the display name] property in search criteria instead of Name , but it does not work.
We get following error - "The playback failed to find the control with the given search properties"
Related problem happens to me also. I solved it by sending the Focus to the UI control before using that control.
Try this.
this.UIAssettePresentationsWindow2.UINOWindow.UINOButton.SetFocus();

TFS-2010 - Custom Work Item Control not showing up: "Form Rendering Failed: Object reference not set to an instance of an object."

I'm developing a custom control for Task/Bug Work Items so I can query for shelvesets related to the Work Item.
First off I tested a simple control with nothing but a listbox with an Item. When I preview the layout form in the Process Editor in VS2010, it shows up alright, but when I create a new Task, upon loading it shows a message instead of my control:
"Form Rendering Failed: Object reference not set to an instance of an object."
What I really like about these error messages is that they're always crystal clear... I'm clueless, what could be causing this behavior?
Thanks in advance!
Clark
~
Place the dll and .wicc of the custom control you created in:
C:\Users\All Users\Microsoft\Team Foundation\Work Item Tracking\Custom Controls\10.0
Make sure your .wicc file directs to your dll correctly.
Refresh the team project in the team explorer.
If your WIT control is functional it should work.
Good Luck!

SharePoint Error - Datasheet View refuses to show up!

Recently the DataSheet view of my list refuses to dispaly. I tried numerouse times and with no luck. Other lists works just fine, except for this one.
there is a Java error message on the left bottom corner of the screen that disapears in 2 seconds, then it renders the list in Standard view any time you try it.
I even created a new Datasheet View - the result a Standard View.
Any suggestions?
Thanks,
Here is a MS site regarding the data sheet view and why it may not be available - http://support.microsoft.com/kb/909506
The error occured after we installed an add-on to restrict users permissions. It looks like this solution afftects the functionality of the site (we tested it for a few days then disable it). Will wait for an improved solution.
http://www.codeplex.com/SPViewPermission

Resources