コード例 #1
0
        private void LoadPortalsList()
        {
            var       portalCtrl = new PortalController();
            ArrayList portals    = portalCtrl.GetPortals();

            SitesLst.ClearSelection();
            SitesLst.Items.Clear();

            SitesLst.DataSource     = portals;
            SitesLst.DataTextField  = "PortalName";
            SitesLst.DataValueField = "PortalID";
            SitesLst.DataBind();

            SitesLst.Items.Insert(0, new ListItem(string.Empty));
        }
コード例 #2
0
        private void LoadPortalsList()
        {
            var portals = PortalController.Instance.GetPortals();

            SitesLst.ClearSelection();
            SitesLst.Items.Clear();

            SitesLst.DataSource     = portals;
            SitesLst.DataTextField  = "PortalName";
            SitesLst.DataValueField = "PortalID";
            SitesLst.DataBind();

            //SitesLst.Items.Insert(0, new ListItem(string.Empty));
            SitesLst.InsertItem(0, string.Empty, string.Empty);
        }