Beispiel #1
0
    XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
    {
        XmlDataSource objData = new XmlDataSource();

        objData.XPath = "siteMap/siteMapNode";
        switch (menu)
        {
        case "Empresa":
            objData.DataFile = serverMapPath + @"\App_Data\Empresa.sitemap";
            break;

        case "Cliente":
            objData.DataFile = serverMapPath + @"\App_Data\Cliente.sitemap";
            break;

        case "Medico":
            objData.DataFile = serverMapPath + @"\App_Data\Medico.sitemap";
            break;

        default:
            break;
        }
        objData.DataBind();
        return(objData);
    }
Beispiel #2
0
    XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
    {
        XmlDataSource objData = new XmlDataSource();
        objData.XPath = "siteMap/siteMapNode";
        switch (menu)
        {
            case "Empresa":
                objData.DataFile = serverMapPath + @"\App_Data\Empresa.sitemap";
                break;
            case "Atendimento":
                objData.DataFile = serverMapPath + @"\App_Data\Atendimento.sitemap";
                break;
            case "Medico":
                objData.DataFile = serverMapPath + @"\App_Data\Medico.sitemap";
                break;
            case "Ambulatorio":
                objData.DataFile = serverMapPath + @"\App_Data\Ambulatorio.sitemap";
                break;
            case "Administrativo":
                objData.DataFile = serverMapPath + @"\App_Data\Administrativo.sitemap";
                break;
            case "Multidisciplinar":
                objData.DataFile = serverMapPath + @"\App_Data\Multidisciplinar.sitemap";
                break;

            default:
                break;
        }
        objData.DataBind();
        return objData;
    }
Beispiel #3
0
    /// <summary>
    /// Carrega os itens do menu conforme perfil logado
    /// </summary>
    /// <param name="menu"></param>
    /// <param name="serverMapPath"></param>
    /// <returns></returns>
    XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
    {
        XmlDataSource objData = new XmlDataSource();

        objData.XPath = "siteMap/siteMapNode";
        switch (menu)
        {
        case "Administrador":     //Caso seja o perfil Administrador carrega o perfil setado no xml
            objData.DataFile = serverMapPath + @"\App_Data\Administrador.sitemap";
            break;

        case "Fisioterapeuta":     //Caso seja o perfil Fisioterapeuta carrega o perfil setado no xml
            objData.DataFile = serverMapPath + @"\App_Data\Fisioterapeuta.sitemap";
            break;

        case "Recepcionista":     //Caso seja o perfil Fisioterapeuta carrega o perfil setado no xml
            objData.DataFile = serverMapPath + @"\App_Data\Recepcionista.sitemap";
            break;

        case "Financeiro":     //Caso seja o perfil Fisioterapeuta carrega o perfil setado no xml
            objData.DataFile = serverMapPath + @"\App_Data\Financeiro.sitemap";
            break;

        default:
            break;
        }
        objData.DataBind();
        return(objData);
    }
Beispiel #4
0
        public void InitMenuDataSource(SiteMapMenus menu, string siteMapPath)
        {
            XmlDataSource menuData = new XmlDataSource();

            menuData.EnableCaching = false;
            menuData.XPath         = "siteMap/siteMapNode";
            menuData.DataFile      = GetMapPath(menu, siteMapPath);
            menuData.DataBind();
            menuRepeater.DataSource = menuData;
            menuRepeater.DataBind();
        }
Beispiel #5
0
    public object GetTreeData(object xml)
    {
        XmlDataSource objXmlDataSource = new XmlDataSource();

        objXmlDataSource.Data          = xml.ToString();
        objXmlDataSource.ID            = "XmlDataSource" + i;
        objXmlDataSource.EnableCaching = false;
        objXmlDataSource.XPath         = "//Module[@ModuleLevel=2]";
        i++;
        objXmlDataSource.DataBind();
        return(objXmlDataSource);
    }
        public void SetMenu(Int32 ModuleID, XmlDataSource xds)
        {
            DataSet ds = GetMenu(ModuleID);

            ds.DataSetName         = "Menus";
            ds.Tables[0].TableName = "Menu";
            DataRelation relation = new DataRelation("ParentChild", ds.Tables["Menu"].Columns["PK_MenuID"], ds.Tables["Menu"].Columns["ParentID"], false);

            relation.Nested = true;
            ds.Relations.Add(relation);
            xds.Data = ds.GetXml();
            xds.DataBind();
        }
Beispiel #7
0
    public override void RenderPage()
    {
        XmlDataSource objXmlDataSource = new XmlDataSource();

        objXmlDataSource.Data = objPowerRule.GetPowerCoteTreeFunctionModuleXml(ModuleTypeID, ModuleCode);

        objXmlDataSource.EnableCaching = false;
        objXmlDataSource.XPath         = "//Module[@ModuleLevel=2]";
        i++;
        objXmlDataSource.DataBind();
        tvwModule.DataSource = objXmlDataSource;
        tvwModule.DataBind();
    }
Beispiel #8
0
        public static void datafile(Page p)
        {
            string originalxml = @"<?xml version=""1.0"" encoding=""utf-8""?><bookstore xmlns:bk=""urn:samples""><book genre=""novel"" publicationdate=""1999"" bk:ISBN=""0192100262""><title>Pride and Prejudice</title><author><first-name>Jane</first-name><last-name>Austen</last-name></author><price>24.95</price>""
			</book><book genre=""novel"" publicationdate=""1985"" bk:ISBN=""0771008139""><title>The Handmaid's Tale</title><author><first-name>Margaret</first-name><last-name>Atwood</last-name></author><price>29.95</price></book></bookstore>"            ;

            XmlDataSource ds = new XmlDataSource();

            p.Form.Controls.Add(ds);
            ds.DataFile = "~/XMLDataSourceTest.xml";
            ds.DataBind();
            string derivedxml = ((XmlDocument)ds.GetXmlDocument()).InnerXml;

            HtmlDiff.AssertAreEqual(originalxml, derivedxml, "Loading xml");
        }
Beispiel #9
0
 /// <summary>
 /// Carrega os itens do menu conforme perfil logado
 /// </summary>
 /// <param name="menu"></param>
 /// <param name="serverMapPath"></param>
 /// <returns></returns>
 XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
 {
     XmlDataSource objData = new XmlDataSource();
     objData.XPath = "siteMap/siteMapNode";
     switch (menu)
     {
         case "Administrador": //Caso seja o analista de credito carrega o perfil setado no xml
             objData.DataFile = serverMapPath + @"\App_Data\Administrador.sitemap";
             break;
         default:
             break;
     }
     objData.DataBind();
     return objData;
 }
    /// <summary>
    /// tab menu items from xml file
    /// </summary>
    protected void bind_tabs()
    {
        string _path = AppDomain.CurrentDomain.BaseDirectory;
        _path += "xml\\form_menus.xml";

        XmlDataSource _xml = new XmlDataSource();
        _xml.DataFile = _path;
        _xml.XPath = "//menuitem[@AppliesTo='Order']"; //you need this or tab will not databind!
        _xml.DataBind();
        //Run time population of GridViewDataComboBoxColumn column with data
        //DevExpress.Web.ASPxTabControl.ASPxTabControl _tab = (DevExpress.Web.ASPxTabControl.ASPxTabControl)this.FindControl("dxtabOrder");
        this.dxtabOrder.DataSource = _xml;
        this.dxtabOrder.DataBind();

    }
Beispiel #11
0
        protected void subMenuRepeater_ItemDataBound(object sender, RepeaterItemEventArgs e)
        {
            Repeater  sRepeter = sender as Repeater;
            HyperLink link     = new HyperLink();

            link.NavigateUrl = DataBinder.Eval(e.Item.DataItem, "url").ToString();
            link.Text        = DataBinder.Eval(e.Item.DataItem, "title").ToString();
            string numNode = DataBinder.Eval(e.Item.DataItem, "description").ToString();

            HtmlGenericControl startLi = new HtmlGenericControl("li");

            Repeater subSubMenuRepeater = new Repeater();

            subSubMenuRepeater.ID             = "subSubMenuRepeater";
            subSubMenuRepeater.ItemDataBound += subSubMenuRepeater_ItemDataBound;

            startLi.Controls.Add(link);
            if (numNode == "parent")
            {
                HtmlGenericControl startUl = new HtmlGenericControl("ul");
                startUl.Controls.Add(subSubMenuRepeater);
                startLi.Controls.Add(startUl);
            }
            else
            {
                startLi.Controls.Add(subSubMenuRepeater);
            }

            e.Item.Controls.Add(startLi);


            if (subSubMenuRepeater != null)
            {
                IXPathNavigable   nav  = e.Item.DataItem as IXPathNavigable;
                XPathNavigator    xnav = nav.CreateNavigator();
                XPathNodeIterator iter = xnav.Select("siteMapNode/siteMapNode");
                if (iter != null && iter.Current != null && iter.Current.HasChildren)
                {
                    XmlDataSource subMenuData = new XmlDataSource();
                    subMenuData.EnableCaching = false;
                    subMenuData.Data          = iter.Current.OuterXml;
                    subMenuData.XPath         = "siteMapNode/siteMapNode";
                    subMenuData.DataBind();
                    subSubMenuRepeater.DataSource = subMenuData;
                    subSubMenuRepeater.DataBind();
                }
            }
        }
Beispiel #12
0
    /// <summary>
    /// tab menu
    /// </summary>
    protected void bind_tabs()
    {
        string _path = AppDomain.CurrentDomain.BaseDirectory;

        _path += "xml\\form_menus.xml";

        XmlDataSource _xml = new XmlDataSource();

        _xml.DataFile = _path;
        _xml.XPath    = "//menuitem"; //you need this or tab will not databind!
        _xml.DataBind();
        //Run time population of GridViewDataComboBoxColumn column with data
        //DevExpress.Web.ASPxTabControl.ASPxTabControl _tab = (DevExpress.Web.ASPxTabControl.ASPxTabControl)this.FindControl("dxtabOrder");
        this.dxtabOrder.DataSource = _xml;
        this.dxtabOrder.DataBind();
    }
Beispiel #13
0
    /// <summary>
    /// Carrega os itens do menu conforme perfil logado
    /// </summary>
    /// <param name="menu"></param>
    /// <param name="serverMapPath"></param>
    /// <returns></returns>
    XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
    {
        XmlDataSource objData = new XmlDataSource();

        objData.XPath = "siteMap/siteMapNode";
        switch (menu)
        {
        case "Administrador":     //Caso seja o analista de credito carrega o perfil setado no xml
            objData.DataFile = serverMapPath + @"\App_Data\Administrador.sitemap";
            break;

        default:
            break;
        }
        objData.DataBind();
        return(objData);
    }
Beispiel #14
0
 XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
 {
     XmlDataSource objData = new XmlDataSource();
     objData.XPath = "siteMap/siteMapNode";
     switch (menu)
     {
         case "Empresa":
             objData.DataFile = serverMapPath + @"\App_Data\Empresa.sitemap";
             break;
         case "Cliente":
             objData.DataFile = serverMapPath + @"\App_Data\Cliente.sitemap";
             break;
         default:
             break;
     }
     objData.DataBind();
     return objData;
 }
Beispiel #15
0
    XmlDataSource GetDataSource(string UserRole, string ServerPath)
    {
        XmlDataSource objData = new XmlDataSource();

        objData.XPath = "siteMap/siteMapNode";
        switch (UserRole)
        {
        case "Specialadmin":
            objData.DataFile = ServerPath + @"/Specialadmin.sitemap";
            break;

        case "Superadmin":
            objData.DataFile = ServerPath + @"/superadmin.sitemap";
            break;

        case "adminmanager":
            objData.DataFile = ServerPath + @"/adminmanager.sitemap";
            break;

        case "manager":
            objData.DataFile = ServerPath + @"/manager.sitemap";
            break;

        case "Account":
            objData.DataFile = ServerPath + @"/Account.sitemap";
            break;

        case "finance":
            objData.DataFile = ServerPath + @"/finance.sitemap";
            break;

        case "user":
            objData.DataFile = ServerPath + @"/user.sitemap";
            break;

        case "Enduser":
            objData.DataFile = ServerPath + @"/Enduser.sitemap";
            break;
        }
        objData.DataBind();
        return(objData);
    }
Beispiel #16
0
        protected void fill_dropdownlist1()
        {
            //Getting selected value of first dropdownlist -Company Name
            DropDownList dropDownList1 = (DropDownList)DetailsView1.FindControl("DropDownList1");
            //string param_company = dropDownList1.SelectedValue;
            string param_company = dropDownList1.Text;

            XmlDataSource xmlDataSource2 = (XmlDataSource)DetailsView1.FindControl("XmlDataSource2");

            xmlDataSource2.DataFile = "~/App_Data/xml/team_member.xml";

            //Filter data in xmlDataSource2 based on selection done
            //Expected syntax xmlDataSource.XPath = "//support/company[@team='HCL']";
            xmlDataSource2.XPath = "//support/company[@team='" + param_company + "']";

            xmlDataSource2.DataBind();

            DropDownList dropDownList2 = (DropDownList)DetailsView1.FindControl("DropDownList2");

            dropDownList2.DataBind();
        }
    /// <summary>
    /// command menu 
    /// </summary>
    protected void bind_formview_commands()
    {
        string _path = AppDomain.CurrentDomain.BaseDirectory;
        _path += "xml\\order_commands.xml";

        XmlDataSource _xml = new XmlDataSource();
        _xml.DataFile = _path;

        _xml.XPath = "//item[@Filter='GenericFormView']"; //you need this or tab will not databind!
        _xml.DataBind();
        //Run time population of GridViewDataComboBoxColumn column with data

        //DevExpress.Web.ASPxMenu.ASPxMenu _mnu = (DevExpress.Web.ASPxMenu.ASPxMenu)this.FindControl("dxmnuCommand");
        //if (_mnu != null)
        //{
        //    _mnu.DataSource = _xml;
        //    _mnu.DataBind();
        //}
        this.dxmnuFormView.DataSource = _xml;
        this.dxmnuFormView.DataBind();

    }
Beispiel #18
0
    /// <summary>
    /// command menu
    /// </summary>
    protected void bind_commands(string mode)
    {
        string _path = AppDomain.CurrentDomain.BaseDirectory;

        _path += "xml\\order_commands.xml";

        XmlDataSource _xml = new XmlDataSource();

        _xml.DataFile = _path;
        _xml.XPath    = "//item[@Filter='" + mode + "']"; //you need this or tab will not databind!
        _xml.DataBind();
        //Run time population of GridViewDataComboBoxColumn column with data

        //DevExpress.Web.ASPxMenu.ASPxMenu _mnu = (DevExpress.Web.ASPxMenu.ASPxMenu)this.FindControl("dxmnuCommand");
        //if (_mnu != null)
        //{
        //    _mnu.DataSource = _xml;
        //    _mnu.DataBind();
        //}
        this.dxmnuToolbar.DataSource = _xml;
        this.dxmnuToolbar.DataBind();
    }
Beispiel #19
0
    XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
    {
        XmlDataSource objData = new XmlDataSource();

        objData.XPath = "siteMap/siteMapNode";
        switch (menu)
        {
        case "Empresa":
            objData.DataFile = serverMapPath + @"\App_Data\Empresa.sitemap";
            break;

        case "Atendimento":
            objData.DataFile = serverMapPath + @"\App_Data\Atendimento.sitemap";
            break;

        case "Medico":
            objData.DataFile = serverMapPath + @"\App_Data\Medico.sitemap";
            break;

        case "Ambulatorio":
            objData.DataFile = serverMapPath + @"\App_Data\Ambulatorio.sitemap";
            break;

        case "Administrativo":
            objData.DataFile = serverMapPath + @"\App_Data\Administrativo.sitemap";
            break;

        case "Multidisciplinar":
            objData.DataFile = serverMapPath + @"\App_Data\Multidisciplinar.sitemap";
            break;

        default:
            break;
        }
        objData.DataBind();
        return(objData);
    }
    protected void bind_toolbar()
    {
        //using generic FormView commands
        string _path = AppDomain.CurrentDomain.BaseDirectory;

        _path += "xml\\order_commands.xml";

        XmlDataSource _xml = new XmlDataSource();

        _xml.DataFile = _path;
        _xml.XPath    = "//item[@Filter='GenericSearchForm']"; //you need this or tab will not databind!
        _xml.DataBind();
        //Run time population of GridViewDataComboBoxColumn column with data

        //DevExpress.Web.ASPxMenu.ASPxMenu _mnu = (DevExpress.Web.ASPxMenu.ASPxMenu)this.FindControl("dxmnuCommand");
        //if (_mnu != null)
        //{
        //    _mnu.DataSource = _xml;
        //    _mnu.DataBind();
        //}
        this.dxmnuToolbar.DataSource = _xml;
        this.dxmnuToolbar.DataBind();
        //int _test = this.dxmnuContainer.Items.Count;
    }
Beispiel #21
0
 /// <summary>
 /// Carrega os itens do menu conforme perfil logado
 /// </summary>
 /// <param name="menu"></param>
 /// <param name="serverMapPath"></param>
 /// <returns></returns>
 XmlDataSource GetMenuDataSource(string menu, string serverMapPath)
 {
     XmlDataSource objData = new XmlDataSource();
     objData.XPath = "siteMap/siteMapNode";
     switch (menu)
     {
         case "Administrador": //Caso seja o perfil Administrador carrega o perfil setado no xml
             objData.DataFile = serverMapPath + @"\App_Data\Administrador.sitemap";
             break;
         case "Fisioterapeuta": //Caso seja o perfil Fisioterapeuta carrega o perfil setado no xml
             objData.DataFile = serverMapPath + @"\App_Data\Fisioterapeuta.sitemap";
             break;
         case "Recepcionista": //Caso seja o perfil Fisioterapeuta carrega o perfil setado no xml
             objData.DataFile = serverMapPath + @"\App_Data\Recepcionista.sitemap";
             break;
         case "Financeiro": //Caso seja o perfil Fisioterapeuta carrega o perfil setado no xml
             objData.DataFile = serverMapPath + @"\App_Data\Financeiro.sitemap";
             break;
         default:
             break;
     }
     objData.DataBind();
     return objData;
 }
    /// <summary>
    /// allocate order to container menu 
    /// </summary>
    protected void bind_order_commands()
    {
        string _path = AppDomain.CurrentDomain.BaseDirectory;
        _path += "xml\\order_commands.xml";

        XmlDataSource _xml = new XmlDataSource();
        _xml.DataFile = _path;
        //these commands moved to bind_container_commands so this menu is not needed
        _xml.XPath = "//item[@Filter='Container']"; //you need this or tab will not databind! "//item[@Filter='NoCommands']";
        _xml.DataBind();
        //Run time population of GridViewDataComboBoxColumn column with data

        //DevExpress.Web.ASPxMenu.ASPxMenu _mnu = (DevExpress.Web.ASPxMenu.ASPxMenu)this.FindControl("dxmnuCommand");
        //if (_mnu != null)
        //{
        //    _mnu.DataSource = _xml;
        //    _mnu.DataBind();
        //}
        this.dxmnuOrder.DataSource = _xml;
        this.dxmnuOrder.DataBind();

    }
Beispiel #23
0
    /* Page Load */
    protected void Page_Load(object sender, EventArgs e)
    {
        //获取页面基页数据
        BasePage owner = (BasePage)Page;


        XmlDataSource xmlDataSource = new XmlDataSource();

        xmlDataSource.ID    = Guid.NewGuid().ToString();
        xmlDataSource.Data  = (Session["ESB_MENU"] as XmlDocument).OuterXml;
        xmlDataSource.XPath = "//DemoGroup";
        xmlDataSource.DataBind();

        //菜单绑定
        nbMenu.DataSource = xmlDataSource;
        nbMenu.DataBind();

        /* Title Image */
        iTitleImage.ImageUrl      = TitleImageUrl;
        iTitleImage.AlternateText = GroupName + "" + Name;

        if (String.IsNullOrEmpty(TitleImageUrl))
        {
            lGroupName.Style.Add(HtmlTextWriterStyle.MarginLeft, "11px");
            iTitleImage.Visible         = false;
            iTitleImage.EnableViewState = false;
        }

        // Header
        string currentUrl = Request.AppRelativeCurrentExecutionFilePath.ToLower();

        if (IsHomePage || Logotype.NavigateUrl.ToLower() == currentUrl)
        {
            Logotype.NavigateUrl = "";
        }

        // Logotype
        Logotype.ImageUrl = "~/App_Themes/" + Page.Theme + "/Demo/LogoESB.png";

        //UserName
        String userName = owner.AuthUser.UserName;

        if (owner.AuthUser.IsVisitor)
        {
            userName += "-访客";
        }

        lblUserName.Text = "【" + userName + "】已登陆";

        if (phOnceContent.Controls.Count != 0)
        {
            tdFooter.Style.Add(HtmlTextWriterStyle.PaddingLeft, "37px");
        }

        if (!String.IsNullOrEmpty(Title))
        {
            Page.Header.Title = Title + Page.Header.Title;
        }

        if (phContent.Controls.Count == 0)
        {
            phContent.Visible          = false;
            phContent.EnableViewState  = false;
            tblTitle.Visible           = false;
            tblTitle.EnableViewState   = false;
            tblHeader.Visible          = false;
            tblHeader.EnableViewState  = false;
            tblFooter.Visible          = false;
            tblFooter.EnableViewState  = false;
            tblContent.Visible         = false;
            tblContent.EnableViewState = false;
        }

        if (phOnceContent.Controls.Count == 0)
        {
            phOnceContent.Visible         = false;
            phOnceContent.EnableViewState = false;
        }
        // general terms
        if (!string.IsNullOrEmpty(GeneralTerms))
        {
            lGeneralTerms.Visible = true;
            lGeneralTerms.Text    = GeneralTerms;
            //pDescription.Controls.Add(new LiteralControl(demoMaster.Description));
        }

        // Title
        lGroupName.Text = Name;// GroupName;
        //lName.Text = Name;
        if (string.IsNullOrEmpty(lName.Text))
        {
            hName.Visible         = false;
            hName.EnableViewState = false;
        }
    }
Beispiel #24
0
    /* Page Load */
    protected void Page_Load(object sender, EventArgs e)
    {
        //��ȡҳ���ҳ����
        BasePage owner = (BasePage)Page;

        XmlDataSource xmlDataSource = new XmlDataSource();
        xmlDataSource.ID = Guid.NewGuid().ToString();
        xmlDataSource.Data = (Session["ESB_MENU"] as XmlDocument).OuterXml;
        xmlDataSource.XPath = "//DemoGroup";
        xmlDataSource.DataBind();

        //�˵���
        nbMenu.DataSource = xmlDataSource;
        nbMenu.DataBind();

        /* Title Image */
        iTitleImage.ImageUrl = TitleImageUrl;
        iTitleImage.AlternateText = GroupName + "" + Name;

        if (String.IsNullOrEmpty(TitleImageUrl)) {
            lGroupName.Style.Add(HtmlTextWriterStyle.MarginLeft, "11px");
            iTitleImage.Visible = false;
            iTitleImage.EnableViewState = false;
        }

        // Header
        string currentUrl = Request.AppRelativeCurrentExecutionFilePath.ToLower();
        if (IsHomePage || Logotype.NavigateUrl.ToLower() == currentUrl)
            Logotype.NavigateUrl = "";

        // Logotype
        Logotype.ImageUrl = "~/App_Themes/" + Page.Theme + "/Demo/LogoESB.png";

        //UserName
        String userName = owner.AuthUser.UserName;
        if (owner.AuthUser.IsVisitor)
            userName += "-�ÿ�";

        lblUserName.Text = "��" + userName + "���ѵ�½";

        if (phOnceContent.Controls.Count != 0)
            tdFooter.Style.Add(HtmlTextWriterStyle.PaddingLeft, "37px");

        if (!String.IsNullOrEmpty(Title))
            Page.Header.Title = Title + Page.Header.Title;

        if (phContent.Controls.Count == 0) {
            phContent.Visible = false;
            phContent.EnableViewState = false;
            tblTitle.Visible = false;
            tblTitle.EnableViewState = false;
            tblHeader.Visible = false;
            tblHeader.EnableViewState = false;
            tblFooter.Visible = false;
            tblFooter.EnableViewState = false;
            tblContent.Visible = false;
            tblContent.EnableViewState = false;
        }

        if (phOnceContent.Controls.Count == 0) {
            phOnceContent.Visible = false;
            phOnceContent.EnableViewState = false;
        }
        // general terms
        if (!string.IsNullOrEmpty(GeneralTerms)) {
            lGeneralTerms.Visible = true;
            lGeneralTerms.Text = GeneralTerms;
            //pDescription.Controls.Add(new LiteralControl(demoMaster.Description));
        }

        // Title
        lGroupName.Text = Name;// GroupName;
        //lName.Text = Name;
        if (string.IsNullOrEmpty(lName.Text)) {
            hName.Visible = false;
            hName.EnableViewState = false;
        }
    }
Beispiel #25
0
    /// <summary>
    /// tab menu 
    /// </summary>
    protected void bind_tabs(string mode)
    {
        string _path = AppDomain.CurrentDomain.BaseDirectory;
        _path += "xml\\form_menus.xml";

        XmlDataSource _xml = new XmlDataSource();
        _xml.DataFile = _path;
        //080814 for Insert mode just display Order detials tab (Titles must be added to a new order)  
        _xml.XPath = string.Format("//menuitem[@AppliesTo='{0}Order']", mode == "Insert"? "Insert": ""); //you need this or tab will not databind!
        //_xml.XPath = "//menuitem[@AppliesTo='Order']"; //you need this or tab will not databind!
        _xml.DataBind(); 
        //Run time population of GridViewDataComboBoxColumn column with data
        //DevExpress.Web.ASPxTabControl.ASPxTabControl _tab = (DevExpress.Web.ASPxTabControl.ASPxTabControl)this.FindControl("dxtabOrder");
        this.dxtabOrder.DataSource = _xml;
        this.dxtabOrder.DataBind(); 
        
    }