1

我正在尝试测试OpenFileDialog当用户单击我的 Silverlight 4.0 应用程序中的按钮时创建的。根据常见问题解答,查找模式对话框的正确方法是:

Window mainWindow = application.GetWindow("main");
List<Window> modalWindows = mainWindow.ModalWindows(); //list of all the modal windows belong to the window.
Window childWindow = mainWindow.ModalWindow("child"); //modal window with title "child"
childWindow.IsModal; //returns true

但是,我正在使用White.WebBrowser.Silverlight.SilverlightDocument该类测试 Silverlight 应用程序,该类似乎没有ModalWindows()集合。

有人可以给我一个提示我做错了什么,以及我应该如何测试这个?

4

1 回答 1

0

viveksingh在 White 论坛上提供了答案:

你试过从 InternetExplorerWindow 对象中找到 ModalWindow 吗?

于 2010-04-08T01:33:51.797 回答