Answered by:
How to Hide People Picker in Infopath 2010

Question
-
How to Hide People Picker in Infopath 2010Friday, August 5, 2011 6:10 AM
Answers
-
If the control needs to be hidden "unconditionally", you can just remove the control and not put it on the form at all. >
Laura Rogers
IW Mentor: SharePoint Training
Blog: http://www.wonderlaura.com
Twitter: WonderLaura
Beginning SharePoint 2010: Building Business Solutions with SharePoint- Marked as answer by Lily Wu Friday, August 12, 2011 8:29 AM
- Edited by LauraRogers MVPMVP Tuesday, May 10, 2016 7:29 PM
Friday, August 5, 2011 8:35 PM
All replies
-
You can always do two things, if you delete the people picker from the design view when you develop the form, it will still exist in the data source. If you want to hide it on runtime, you can click on it, and select manage rules, then click formatting, and based on any condition, hide the control.
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.com- Proposed as answer by Udayakumar Ethirajulu Friday, August 5, 2011 1:52 PM
Friday, August 5, 2011 6:53 AM -
Put a "Section" on the form, add the People picker to the section. Add a formatting rule that hides the section based on some criteria in the form.
There are a few controls that formatting does not hide, for these I always place in a Section and apply rules to it.
- Proposed as answer by Derek.Wilkes Friday, August 5, 2011 11:44 AM
Friday, August 5, 2011 11:44 AM -
Why hiding the section if you can hide the people picker itself?
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.comFriday, August 5, 2011 1:16 PM -
Just put a formatting rule on the person picker and select any of the 3 displayed items (DisplayName, AccountId, AccountType) and use "is Blank" condition if it always stayss blank. If it always have a value in it then use "is not Blank" Condition.
This particular control can me hidden, so there is no need to put it in a section and hide the section. That will be wasting time and computing power.
Learning with everyoneFriday, August 5, 2011 1:47 PM -
Why hiding the section if you can hide the people picker itself?
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.com
Sorry, but in that case the reality is slightly differs from your perception. No you can't hide it this way. Thats why it was recommended to put it inside the section.
Edit: actually I see many people who is recommending not to put People Picker into the section. To all of you - create empty form, place People Picker on layout and unconditionaly apply hide rule. Open preview. I promise, all of you will make a small discovery.
http://alecpojidaev.wordpress.com- Proposed as answer by Derek.Wilkes Friday, August 5, 2011 4:41 PM
Friday, August 5, 2011 4:15 PM -
Why hiding the section if you can hide the people picker itself?
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.com
Sorry, but in that case the reality is slightly differs from your perception. No you can't hide it this way. Thats why it was recommended to put it inside the section.
http://alecpojidaev.wordpress.com
Alec,
Have you ever used InfoPath 2010? Try dragging a people picker control, click on it, then manage rules, then formatting, and hide it. As easy as that!
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.comFriday, August 5, 2011 4:31 PM -
Sorry, Hiding PP without using section doesn't work in both IP 2010 and 2007.
http://alecpojidaev.wordpress.com
Friday, August 5, 2011 4:34 PM -
Well, try it!
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.comFriday, August 5, 2011 6:04 PM -
With all due respect, yes it does Hide even if you do not use a section. Just tried it myself again and got it hidden in the preview. Here is what I DID:
1. Open IP2010. Select New Blank Form Template. All PP to the blank page.
2. Select PP. Click Manage Rules. Click New Drop Down and selected Formatting.
3. In condition put "Field1" "is Blank". Selected "Hide this control" Checkbox.
4. Click Preview or press F5. The form comes up blank.
So "Alec Pojidaev" and "Darek Wilkes" Please check it again. You are mistaken here.
No disrespect meant. Just trying to clarify the issue
Learning with everyoneFriday, August 5, 2011 6:05 PM -
Read my post!
I never said it could not be hidden out of a Section. I simply gave an alternative to the problem. Sometimes there is more than one way to accomplish an end result.
I use Sections very frequently since it allows me to control many items with less rules.
Thank you!
Derek
- Proposed as answer by Derek.Wilkes Friday, August 5, 2011 6:10 PM
Friday, August 5, 2011 6:09 PM -
Yep you guys are right no section needed. I was able to hide it. Although if you try to hide it unconditionally (not specifying any condition) it wont hide.
http://alecpojidaev.wordpress.comFriday, August 5, 2011 6:12 PM -
That is correct! Conditions are always needed!Friday, August 5, 2011 6:12 PM
-
You don't need conditions too!! Just make the condition to be formula, IF 1 =1 THEN HIDE!!! that's it. So it's going to be hidden unconditionally.
Bottom line is, you can hide it whenever you want, based on any condition you want. without depending on another values, without depending on another sections.
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.comFriday, August 5, 2011 8:24 PM -
If the control needs to be hidden "unconditionally", you can just remove the control and not put it on the form at all. >
Laura Rogers
IW Mentor: SharePoint Training
Blog: http://www.wonderlaura.com
Twitter: WonderLaura
Beginning SharePoint 2010: Building Business Solutions with SharePoint- Marked as answer by Lily Wu Friday, August 12, 2011 8:29 AM
- Edited by LauraRogers MVPMVP Tuesday, May 10, 2016 7:29 PM
Friday, August 5, 2011 8:35 PM -
Yes Laura, that's exactly what I posted in the first reply, but we got carried out by the "SECTION" thing.
Mohamed Derhalli ||| SharePoint Specialist ||| http://path2sharepoint.comFriday, August 5, 2011 9:29 PM