IsControlPresent() публичный Метод

public IsControlPresent ( ) : bool
Результат bool
Пример #1
0
        public WebControl GetControl(Locator aLocator, ControlType aControlType)
        {
            WebControl aWebCustomControl;

            switch (aControlType)
            {
            case ControlType.Button:
                aWebCustomControl = new WebButton(myBrowser, aLocator);
                break;

            case ControlType.EditBox:
                aWebCustomControl = new WebEditBox(myBrowser, aLocator);
                break;

            default:
                aWebCustomControl = new WebControl(myBrowser, aLocator);
                break;
            }

            if (aWebCustomControl.IsControlPresent())
            {
                aWebCustomControl.GetControl();
            }

            return(aWebCustomControl);
        }
Пример #2
0
        public WebControl GetControl(Locator aLocator)
        {
            WebControl aWebCustomControl = new WebControl(myBrowser, aLocator);

            if (aWebCustomControl.IsControlPresent())
            {
                aWebCustomControl.GetControl();
            }

            return(aWebCustomControl);
        }