protected override void CreateChildControls()
        {
            SPUser currentUser = SPContext.Current.Web.CurrentUser ;
            //站点管理员可以编辑所有字段
            if (currentUser.IsSiteAdmin&&(!this.Page.IsPostBack))
            {
                base.CreateChildControls();
                return;
            }
这段代码被调用无数次,是不是base的毛病?应该怎么改?

解决方案 »

  1.   

    base.CreateChildControls(); 这的毛病
      

  2.   

    我想调用父类的createchildcontrols怎么弄?
      

  3.   

    base是调用父类的啊。子类重写了也是用base调用的啊。貌似没问题
      

  4.   

    base没错啊,问题是子类的那个方法在哪儿调用了
      

  5.   

    看看子类的 CreateChildControls方法在哪里调用了。
      

  6.   

    子类的方法CreateChildControls在外面可能被死循环调用了
      

  7.   

    没发现代码有问题,如果是死循环的话我估计是CreateChildControls(); 这里出了问题!
      

  8.   

    base是不是调用基类的方法啊?不调用本类的方法吧?
      

  9.   

    wa, SharePoint,楼主用得开心吗?
      

  10.   

    hihand,这都看得出来是sharepoint