Getting the Current User Name or ID in SharePoint using SharePoint Designer no code – Josh Gaffeys Blog – Site Home – MSDN Blogs


REMOTE_USER

via Getting the Current User Name or ID in SharePoint using SharePoint Designer no code – Josh Gaffeys Blog – Site Home – MSDN Blogs.

While looking for a resolution to an issue with filtering a SharePoint 2010 List View, I came across this. We have a column that is a multi-line text column that is populated via workflow with the userids of members of a group.
After some consternation trying to resolve using the [Me] or the [Current User] option with a contains, I had just about given up.
resolution though in the form of…open the page in SharePoint Designer and locate the webpart hosting the list. It is a Data View Web Part, go to the Filters section and create a new filter: choose your column, choose contains, choose new parameter. create this new parameter based on Server Variable Logon User.
Bam! mission accomplished…or at least this battle won. I live to fight the next battle

Advertisements

Published by

wattersbill72

Dad, Husband, Brother, Son , Soccer Player/Fan, SharePoint Person, All Around Geek

2 thoughts on “Getting the Current User Name or ID in SharePoint using SharePoint Designer no code – Josh Gaffeys Blog – Site Home – MSDN Blogs”

  1. I’ve been using this approach for a while but with 2013 we switched to claims AuthN and now Server Variable Logon User comes back with all the claims garbage in front of the user name. Do you know of another way to get the Logon User or how to clean the server variable in the ParameterBinding Location attribute? Thanks!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s