当前位置: 首页>>代码示例>>C#>>正文


C# RadioButtonList.ClearSelection方法代码示例

本文整理汇总了C#中System.Web.UI.WebControls.RadioButtonList.ClearSelection方法的典型用法代码示例。如果您正苦于以下问题:C# RadioButtonList.ClearSelection方法的具体用法?C# RadioButtonList.ClearSelection怎么用?C# RadioButtonList.ClearSelection使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在System.Web.UI.WebControls.RadioButtonList的用法示例。


在下文中一共展示了RadioButtonList.ClearSelection方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: SelectItem

 /// <summary>
 /// Selects and item in the radio button list control by the item value.
 /// This is available as a property of the control in .Net 1.1
 /// </summary>
 /// <param name="control"></param>
 /// <param name="value"></param>
 public static void SelectItem(RadioButtonList control, string value)
 {
     control.ClearSelection();
     ListItem item = control.Items.FindByValue(value);
     if (item != null)
         item.Selected = true;
 }
开发者ID:williamesharp,项目名称:Aspose_Email_NET,代码行数:13,代码来源:WebUtil.cs

示例2: SelectValueRadio

        public void SelectValueRadio(RadioButtonList RadioButtonList, string value)
        {
            ListItem item = RadioButtonList.Items.FindByValue(value);

            if (item != null)
            {
                RadioButtonList.ClearSelection();
                item.Selected = true;
            }
        }
开发者ID:yeanmagu,项目名称:HGI2,代码行数:10,代码来源:Principal.Master.cs

示例3: BindSearchConditionOperator

 /// <summary>
 /// Binds the search condition operator.
 /// </summary>
 /// <param name="saveSearchDoc">The save search doc.</param>
 /// <param name="saveSearchName">Name of the save search.</param>
 /// <param name="rdblSearchConditionList">The RDBL search condition list.</param>
 protected void BindSearchConditionOperator(XmlDocument saveSearchDoc, string saveSearchName, RadioButtonList rdblSearchConditionList)
 {
     if(saveSearchDoc != null)
     {
         XmlNode xmlNodeSaveSearch = saveSearchDoc.SelectSingleNode("saveSearchRequests/saveSearchRequest[@name='" + saveSearchName + "']");
         XmlNode xmlNodeOperator = null;
         if(xmlNodeSaveSearch != null)
         {
             xmlNodeOperator = xmlNodeSaveSearch.SelectSingleNode("requestinfo/entity/attributegroup");
         }
         if(xmlNodeOperator != null && xmlNodeOperator.Attributes["operator"] != null)
         {
             if(rdblSearchConditionList.Items.FindByText(xmlNodeOperator.Attributes["operator"].Value) != null)
             {
                 rdblSearchConditionList.ClearSelection();
                 rdblSearchConditionList.Items.FindByText(xmlNodeOperator.Attributes["operator"].Value).Selected = true;
             }
             else if(rdblSearchConditionList.Items.FindByValue(xmlNodeOperator.Attributes["operator"].Value) != null)
             {
                 rdblSearchConditionList.ClearSelection();
                 rdblSearchConditionList.Items.FindByValue(xmlNodeOperator.Attributes["operator"].Value).Selected = true;
             }
         }
         else
         {
             rdblSearchConditionList.SelectedIndex = 0;
         }
     }
 }
开发者ID:vijaymca,项目名称:Dotnet,代码行数:35,代码来源:UIControlHandler.cs


注:本文中的System.Web.UI.WebControls.RadioButtonList.ClearSelection方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。