CreateControlFromResource() public method

public CreateControlFromResource ( string resourceName ) : Control
resourceName string
return System.Web.UI.Control
示例#1
0
        private Control GetCtrl(Control X)
        {
            cu = new BasicControlUtils(X);
            Control userControl = cu.CreateControlFromResource("Carrotware.Web.UI.Controls.ucSimplePager1.ascx");

            return(userControl);
        }
        private Repeater GetCtrl(Control ctrl)
        {
            Repeater r = new Repeater();

            try {
                BasicControlUtils cu          = new BasicControlUtils(ctrl);
                Control           userControl = cu.CreateControlFromResource("Carrotware.Web.UI.Controls.ucFancyPager.ascx");
                r = (Repeater)cu.FindControl("rpPager", userControl);
            } catch { }

            return(r);
        }
示例#3
0
        private Control GetCtrl(Control X)
        {
            cu = new BasicControlUtils(X);
            Control userControl = cu.CreateControlFromResource("Carrotware.Web.UI.Controls.ucSimplePager1.ascx");

            return userControl;
        }
示例#4
0
        private Repeater GetCtrl(Control ctrl)
        {
            Repeater r = new Repeater();

            try {
                BasicControlUtils cu = new BasicControlUtils(ctrl);
                Control userControl = cu.CreateControlFromResource("Carrotware.Web.UI.Controls.ucFancyPager.ascx");
                r = (Repeater)cu.FindControl("rpPager", userControl);
            } catch { }

            return r;
        }