Click gmail signout link using Watin
I am using IE8 and IE9 on 2 different machines and I want to click the signout link of my gmail account.
Watin 开发者_StackOverflowis unable to find the signout link and gives me error.
Could anyone please help me and let me know how can I achieve this.
Thanks Yasir
expecting you have created a browser instance I think this will do the trick:
var signOutBtn = browser.Frame("canvas_frame").Link(Find.ByText("Sign out"));
signOutBtn.Click();
BTW be sure to update to WatiN 2.1 which supports frames in IE9 properly.
精彩评论