示例#1
0
        /// <summary>
        /// Get value of field indicated by field name
        /// </summary>
        /// <param name="fieldName">Field name</param>
        public string GetFieldValueByLabel(string fieldName)
        {
            var fieldLocator = new ByLabelTextLocator(fieldName);

            return(GetFieldValue(fieldLocator));
        }
示例#2
0
        /// <summary>
        /// Set value for field with given label's text
        /// </summary>
        /// <param name="labelText">Label text</param>
        /// <param name="value">Value to set for field</param>
        /// <param name="customAction">Action to perform after field value has been set</param>
        public void SetFieldValueByLabel(string labelText, string value, AfterFieldValueSet?customAction = null)
        {
            var fieldLocator = new ByLabelTextLocator(labelText);

            SetFieldValue(fieldLocator, value, customAction);
        }