I am using a generic dialog to identify a message box.
I provided all required details like:
Dialog Title
MatchPartial Title checkbox
ChildWindow text content
Button Partial text
Button id
Handle time out
But when i convert it into C# code,
the ButtonPartialText and ButtonId arguments are nowhere in that code.
Those two informations must be there.
Thanks,
Prachi
8 Answers, 1 is accepted
are you sure it's "Generic" dialog you're referring to (screenshot 1)? This dialog cannot be turned to code (screenshot 2). Could you please clarify?
All the best,
Yes i am using Generic dialog and we can see its code if we use convert all steps into code option see image1 fot that.
and image2 is its code transaltion.
Looks like we have a code generation bug. Thanks for pointing this out to us!
Try this constructor instead:
GenericDialog genericDialog =
new
GenericDialog(ActiveBrowser,
"dialog title here"
,
true
,
"button text here"
,
""
);
Cody
I am facing an issue with a generic dialog, not able to do actions on it from my code, please find my code below, this is a unit test code generated using Test Studio. When I run the recorded test (*.tstest) from VS plugin, the code works.
GenericDialog RowDelete = new GenericDialog(ActiveApplication, "Delete", true, "");
RowDelete.ButtonText =
"Cancel";
Manager.Current.DialogMonitor.AddDialog(RowDelete);
Console.WriteLine("Delete dialog text : " + RowDelete.ButtonText);
RowDelete.WaitUntilHandled(5000);
/*****************************************/
I am getting following error,
/*****************************************/
System.TimeoutException: Timed out waiting '5000' msec. for any dialog to be handled '1'
Result StackTrace:
at ArtOfTest.WebAii.Win32.Dialogs.BaseDialog.WaitUntilAnyHandled(IEnumerable`1 dialogs, Int32 handleCount, Int64 timeoutMilliseconds, Boolean resetHandleCount)
at ArtOfTest.WebAii.Win32.Dialogs.BaseDialog.WaitUntilHandled(Int32 handleCount, Int32 timeout, Boolean resetHandleCount)
at
Kindly help me thanks in advance.
Regards
Chery Jose
I am sorry to hear that you are experiencing this issue.
The code that you should use should look similar to this code sample:
Manager.Current.DialogMonitor.AddDialog(RowDelete);
Manager.Current.DialogMonitor.Start();
//you need add here some code to get to the dialog
RowDelete.WaitUntilHandled(5000);
Manager.Current.DialogMonitor.Stop();
If this doesn't help you, is there a way you can provide us with a copy of your test and if it is possible grant us access to your application so we can reproduce the issue on our end and give you a solution.
If you decide to do so you can open a support ticket instead of forum thread where all the information provided remains confidential.
Velin Koychev
Telerik
Test Studio Trainings
Hi Telerik Team,
Almost from week, I am trying to select a cert from auto populated Win32 Generic Dialog Box and supply PIN after proper cert selection but no luck yet.
When I run Record function in Chrome browser, It records process but does not add steps of Cert selection and PIN Supply. During Run recorded steps Page navigates to browser and stops at Cert selection page. I had to click certs manualy and move forward with manual steps. I did try to Add step using Step Builder Dialog Element with Alert, Confirme , Prompt and Generic Steps but it does not pick the cert or do any thing. Can you help me with proper solution please?
When I record and run in IE Broser it records and run but in case if I will have to select another cert, It does not provide option to select next cert either by Index or text.
Your help would be highly appreciated.
Regards;
Nagmani
Please note that the thread you pointed to is related to quite older version of Test Studio. However I reviewed the details and screenshots you provided. Obviously there is difference in what IE and Chrome detects while handling the certificate dialog. Since the issue appears while recording I will certainly need to be able to reproduce that behavior on my side to continue the investigation. Would it be possible to provide access to your application along with your test?
If the above request could not be accomplished there is one more opportunity and this is to provide us a Fiddler trace of the problem page. We have about a 75% success rate using a Fiddler trace to simulate your web server and reproduce problems. To capture the trace please follow these steps:
1 Start Fiddler - note no browser should be open
2 Click Clear Cache
3 If your site uses HTTPS click Decrypt HTTPS traffic
4 Start Capture
5 Launch a browser
6 Navigate to the problem page and pop up.
7 Stop Capture
8 Save Capture
9 Put the .SAZ file into a .zip file and attach that to this support ticket
Looking forward to hearing from you!
Regards,
Elena Tsvetkova
Telerik by Progress
Test Studio Trainings