开发者

Need a way to perform auto confirm for firefox or any other browser popup's

Is there a way to auto confirm popup. For example i'm deletin开发者_StackOverflowg file via firefox this operation triggers a confirmation popup when the options are ok and cancel.

In this case i need to click on ok button automatically.


Found a way to do this in C#:

Perform the desired action (like delete) and then:

    SendKeys.SendWait("{ENTER}"); //in case if the focus was on ok button


    SendKeys.SendWait("{TAB}"); //in case if the focus was on cancel button
    SendKeys.SendWait("{ENTER}"); 
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜