コード例 #1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!StopProcessing)
     {
         ReloadData();
     }
     else
     {
         // Get disabled item indexes and disable them
         string[] indexes = DisabledItems.TrimEnd('|').Split('|');
         DisabledItems = string.Empty;
         int cnt = drpCategories.Items.Count;
         foreach (int i in indexes.Select(index => ValidationHelper.GetInteger(index, -1)).Where(i => (i >= 0) && (i < cnt)))
         {
             DisableItem(drpCategories.Items[i]);
         }
     }
 }
コード例 #2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!StopProcessing && !URLHelper.IsPostback())
     {
         ReloadData();
     }
     else
     {
         // Get disabled item indexes and disable them
         string[] indexs = DisabledItems.TrimEnd('|').Split('|');
         DisabledItems = string.Empty;
         int cnt = drpCategories.Items.Count;
         foreach (string index in indexs)
         {
             int i = ValidationHelper.GetInteger(index, -1);
             if (i >= 0 && i < cnt)
             {
                 DisableItem(drpCategories.Items[i]);
             }
         }
     }
 }