Winium.Desktop icon indicating copy to clipboard operation
Winium.Desktop copied to clipboard

NoSuchElementException : Element cannot be found for calculator for C#

Open SaveliyShur opened this issue 3 years ago • 0 comments

Don't work: var window = driver.FindElementByClassName("CalcFrame"); I see my calculator but i have OpenQA.Selenium.NoSuchElementException : Element cannot be found in this string.

        var dc = new DesiredCapabilities();
        dc.SetCapability("app", @"C:/windows/system32/calc.exe");
        var driver = new RemoteWebDriver(new Uri("http://localhost:9999"), dc);

        var window = driver.FindElementByClassName("CalcFrame");
        var resultField = window.FindElement(By.Id("150"));
        resultField.GetAttribute("Name");

        driver.Quit();

I change class name, and i start driver.

SaveliyShur avatar Apr 18 '21 00:04 SaveliyShur