This is a migrated thread and some comments may be shown as answers.

WPF - Dialog Box Unexpected unless logging?

2 Answers 102 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Mark
Top achievements
Rank 1
Mark asked on 27 Apr 2016, 12:35 PM

WPF Application Dialog problem

So I have a bit of a strange problem with my test, so far handling Save As Dialogs have gone well, however this particular Save Dialog is not being 'detected' as a Save As Dialog. The title of the window is "Select an Export File" and my problem occurs when I click on the button to open this window, when it's opened I can see in the log file made by Test Studio that it is considered an "Unexpected Dialog". And then test studio won't handle it as a SaveAsDialog. However, when I set the UnexpectedDialogAction to Handle and Continue, what would be the Save As Dialog box is closed as fast as it is opened and if I open the Save As Dialog box again, then Telerik recognizes it as a Save As Dialog and not an UnexpectedDialog. Where this gets even more complex is when I take off Test Studio logging, the Dialog never changes to a Save As Dialog, and Test studio keeps recognizing it as an unexpected dialog no matter how many times I click on the button that opens this.

 

Any ideas on how I can fix this? Very confused about this issue.

 

Manager.Settings.UnexpectedDialogAction = UnexpectedDialogAction.HandleAndContinue;

2 Answers, 1 is accepted

Sort by
0
Mark
Top achievements
Rank 1
answered on 29 Apr 2016, 01:12 PM
After spending an embarrassing amount of time I'm a bit ashamed to say the solution we used to this problem, we simply just entered the file path we'd like to save to using the keyboard and sent an enter key and that works instead of relying on the SaveAsDialogHandler. Still curious as to why this behaviour occurs with the differences in logging and not logging as well as the box sometimes being considered Unexpected Dialog and Save As Dialog.
0
Elena
Telerik team
answered on 02 May 2016, 06:07 AM
Hello Mark,

Thank you for the detailed description. I am glad to hear you were able to figure out and handle the encountered issue. That sounds quite odd but to provide any root cause of that unexpected behavior we will need access to the particular application or a sample one that replicates the same for further investigation. It will be helpful if you are able to grant access to your application and share your project. 

Do not hesitate to contact us in case of any future queries. 

Regards,
Elena Tsvetkova
Telerik
 
The New Release of Telerik Test Studio Is Here! Download, install,
and send us your feedback!
Tags
General Discussions
Asked by
Mark
Top achievements
Rank 1
Answers by
Mark
Top achievements
Rank 1
Elena
Telerik team
Share this question
or