SharePoint 2013 WebPart属性面板配置

为WebPart添加右侧的属性面板,方便将来对于WebPart的配置,我们只需要在CustomWebPart.cs文件里面,声明一下变量即可:

private string url = string.Empty;
        [WebBrowsable(true)]
        [WebDisplayName("浏览页地址")]
        [WebDescription("配置杂草信息的浏览页地址")]
        [Category("杂项设置")]
        [Personalizable(true)]
        public string thisurl
        {
            get
            {
                return url;
            }
            set
            {
                url = value;
            }
        }
        

参考:http://www.cnblogs.com/jianyus/p/3458374.html

上一篇:Struts2.0+Spring3+Hibernate3(SSH~Demo)


下一篇:Codeforces Round #523 (Div. 2)