开发者

People Picker AllowEmpty Property

I am using the people picker user control of SharePoint in my aspx page. I have set the AllowEmpty property of people picker control as false.

But, still the required field validat开发者_JAVA百科ion is not occurring for the control. I don't want to use a required field validation control explicitly for validating this. Any insights?

Regards, Raghuraman.V


In order to enable/disable validation for Entity Editor based controls (like People Editor) the following properties should be specified in combination:

  • AllowEmpty - represents whether an empty entity is allowed
  • ValidatorEnabled - represents whether a Validator is enabled

So, in your case to disable empty values, ValidatorEnabled="true" should be provided also like shown below:

<wssawc:PeopleEditor
                                      AllowEmpty="false"
                                      ValidatorEnabled="true"
                                      id="userPicker"
                                      runat="server"
                                      SelectionSet="User,SecGroup"
                                      />
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜