MOSS Forum

 
Home » Forum » MOSS       Ask a questionRSS Feeds

Hiding List form fields by user rights in Moss 2007

  Asked By: Tabatha Salazar         Date: May 07, 2009      Category: MOSS      Views: 1411
 

Is there any way, using SharePoint Designer, to make a standard lists
form field visible or invisible by user rights?

I have the following Example list:

Name
Address
Phone Number

I want to make the phone number field in the form invisible to some
users and visible to others.

I want to do the same in the Edit Item form.

Any ideas?

Why did MS leave out the capability to make fields in forms
invisible/visible per user access rights?

Tagged:                    

 

7 Answers Found

 
Answer #1       Answered By: Rafael Willis          Answered On: May 07, 2009       

This requires custom code and can't be done just with SPD.

BTW, they didn't leave it out. In the previous version (SharePoint 2003)
Security only went down to the whole library or list  level. In 2007 its been
pushed down to the list item level. Hopefully in the next release they'll take
it the next step to the field level. In the meantime there are ways to do this,
but all of them require custom coding.

 
Answer #2       Answered By: Varun Mehta          Answered On: May 07, 2009       
 
Answer #3       Answered By: Junior Jarvis          Answered On: May 07, 2009       

I've looked at this Q a lot since we have this requirement. I'm not a guru nor
a coder, but here's what we did using only the GUI and SPD on a MOSS site.

We made custom edit forms and eMailed links to these edit forms to persons
where column level security was/is needed. These custom edit forms changed the
required fields  from "edit" to "display." Thus, the user  cannot change them.

However, they can backtrack to the underlying list  and change anything. So, we
shut down the browser after they hit the "save" button.

Not perfect, but it works. BTW, these ideas came from other folks & blogs, not
me.

 
Answer #4       Answered By: Sanjay Lohar          Answered On: May 07, 2009       

I see that my thoughts
about making field visibility and selectability by user  permissions
is shared by a number of people.

One area that this is vital is when you do lists with salary
information in a number of fields.

Right now, I am trying to build a Salary Review list  for HR and all
of our supervisiors and managers. The list will contain, Names, Last
Salary increase, and a whole bunch of other data associated with the
the Employee.

The criteria is that Supervisors can see their own employees but not
other supervisors employees, and can see some fields, while managers
can see all fields  relative to the employees under them. But
Managers can not see those fields TOP Executives enter information
into.

Using SharePoint out of the Box, I can do almost everything I need
except hiding  fields by permissions,or by selection. IF I had that
capability, I'd be home free.

Since there is one master list that contains all this information, it
is imperative that you can selectively turn on and off fields in the
FORM itself,in NEW, EDIT, DISPLAY.

Hope Microsoft is Listening for putting this in the next release.

 
Answer #5       Answered By: Mason Salazar          Answered On: May 07, 2009       

I did something similar, and to hide and show rows (fields) of the
custom form  according to certain permissions, you can use the
Conditional Formatting feature!

After you've inserted your custom form into the page in SharePoint
Designer, here's what you do.
In this example, I want to only show this field to people who have
"Approval" rights  on the list:

1. Select the whole row that contains the field that you want to hide.
2. In Conditional Formatting, click <Create> and choose <show content>
3. Click <Advanced...>
4. In the expression box, put:
ddwrt:IfHasRights(16)

5. Click OK twice
6. Where did I get this mysterious "16" number?

http://www.wssdemo.com/blog/archive/2007/08.aspx
<http://www.wssdemo.com/blog/archive/2007/08.aspx>

Someone named Ian has listed all of the types of rights, and the
associated number. For example, "edit" is equal to 4.

 
Answer #6       Answered By: Jesus Davis          Answered On: May 07, 2009       

Very intreguing indeed!!! I'm going to try what you listed and see
how it works.

Thank you so much for looking thru the posts to find this one, which
I made in Sept. 2008.

I still think MicroSoft should make it easy for us to do fields
permissions as mentioned in this thread in the next update.

 
Answer #7       Answered By: Narasimha Kamane          Answered On: May 07, 2009       

I know an add-on in www.sharepointboost.com which can help you making
some row unvisible while others read-only or editable.

 
Didn't find what you were looking for? Find more on Hiding List form fields by user rights in Moss 2007 Or get search suggestion and latest updates.


Your Answer
  • Answer should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].