---
schema_version: "1"
id: 057cdfadb45e602655780fea1c90cc706f83b84bccaf22cb9b01e7bd47068c6d
title: Invalid User (SharePoint or C#)
collection: tableau
version: current
locale: en-us
portal_url: https://docs.salesforce.com/tableau/current/en-us/server/trusted_auth_trouble_invaliduser.md
canonical_url: https://help.tableau.com/current/server/en-us/trusted_auth_trouble_invaliduser.htm
source_site: help.tableau.com
content_type: documentation
content_hash: a8554e89ac69635a27ad46d961618367e472f81f6a215f1886485d5be8951956
description: Resolve the Invalid User error in SharePoint or C# trusted authentication.
---
[Skip to main content](#main-content)

# Invalid User (SharePoint or C#)

You may encounter this error if you’ve configured Tableau Server for trusted authentication.

The example code for the SharePoint .dll references the following GET request:

SPContext.Current.Web.CurrentUser.Name

The above request will return the display name of the current Windows Active Directory user. If you want to use the login ID, then you will need to change the code to:

SPContext.Current.Web.CurrentUser.LoginName

After you make the change, recompile the SharePoint .dll.