Here is the Selenium RC code for selenium.Uncheck in Webdriver. This code is in Visual Studio C#
public void Uncheck(string xpath)
{
if (driver.FindElement(By.XPath(xpath)).Selected)
{
driver.FindElement(By.XPath(xpath)).Click();
Here is the Selenium RC code for selenium.Check in Webdriver. This code is in Visual Studio C#
public void Check(string xpath)
{
if (!driver.FindElement(By.XPath(xpath)).Selected)
{
driver.FindElement(By.XPath(xpath)).Click();
Here is the Selenium RC code for selenium.SelectWindow in Webdriver. This code is in Visual Studio C#
public void SelectWindow(string Text)
{
driver.SwitchTo().Window(Text);
}
Here is the Selenium RC code for selenium.SelectFrame in Webdriver. This code is in Visual Studio C#
public void SelectFrame(string xpath)
{
driver.SwitchTo().Frame(xpath);
}
Here is the Selenium RC code for selenium.DeleteAllVisibleCookies in Webdriver. This code is in Visual Studio C#
public void DeleteAllVisibleCookies()
{
driver.Manage().Cookies.DeleteAllCookies();
}
Here is the Selenium RC code for selenium.waitForElementPresent in Webdriver. This code is in Visual Studio C#
public bool waitForElementPresent(string Xpath)
{
bool present = false;
for (int second = 0; ; second++)
{
if (second >= 5)
{
break;
}
if (IsElementPresent(Xpath))
{
present = true;
break;
}
Thread.Sleep(1000);
}
return present;
}