/// <inheritdoc/>
        public TControlObject SelectPerIndex(ControlSelectionContext context, int index)
        {
            ArgumentUtility.CheckNotNull("context", context);

            var hasAttributeCheck = XPathUtils.CreateHasAttributeCheck(DiagnosticMetadataAttributes.ControlType, _controlType);
            var scope             = context.Scope.FindXPath(string.Format("(.//*{0})[{1}]", hasAttributeCheck, index));

            return(CreateControlObject(context, scope));
        }
Exemple #2
0
        /// <inheritdoc/>
        public TextBoxControlObject SelectPerIndex(ControlSelectionContext context, int index)
        {
            ArgumentUtility.CheckNotNull("context", context);

            var hasAttributeCheck = XPathUtils.CreateHasAttributeCheck("type", "text");
            var xPathSelector     = string.Format("(.//{0}{1})[{2}]", c_htmlTextBoxTag, hasAttributeCheck, index);
            var scope             = context.Scope.FindXPath(xPathSelector);

            return(CreateControlObject(context, scope));
        }