Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I have a SharePoint 2007 custom list with the column Manager.

When creating a new item I want the NewForm.aspx to autopulate the Manager field with the user's manager.

I know we can autopulate using JQuery to access Sharepoint's 'User Information List' exposed as a webservice, as per Marc's blog.

My problem is the Manager is not stored in the 'User Information List' so I can not retrieve it this way, anyone have any ideas?

share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

Thanks Mike, - using MOSS, though half my question was if there was a jquery helper to query this webservice ;)

I did this by writing a custom webpart that using the object model to get the user manager and department.

I then tweaked the URL of the custom list form by adding ?ToolPaneView=2 to the URL. This enabled the edit page. I then added my custom webpart and hid it. Then I added a custom editor webpart which I hid as well. \ I modified the custom list form in SP Designer to use labels instead of form fields then I used the custom editor webpart to write some jquery to copy the values from my custom webpart to the label text.

phew! all that just for some standard auto form filling... :S

share|improve this answer
add comment

Are you using WSS or MOSS? If you are using MOSS and have the manager field being populated from Active Directory then you can make a web service call to the UserProfileService and grab the user's profile, which will include that field.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.