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 use SharePoint 2013 and I need to change my current user in my SharePoint site.

How can I change my current user?

How can I add sub menu (sign in as different user) to my menu ?

enter image description here

share|improve this question
add comment

5 Answers

up vote 14 down vote accepted

Here is Microsoft solution: http://support.microsoft.com/kb/2752600

Basically, start the browser as a different user.

Another solution (but dirty) is to edit the Welcome.aspx file and add a control:

<SharePoint:MenuItemTemplate runat="server" ID="ID_LoginAsDifferentUser" Text="<%$Resources:wss,personalactions_loginasdifferentuser%>" Description="<%$Resources:wss,personalactions_loginasdifferentuserdescription%>" MenuGroupId="100" Sequence="100" UseShortId="true" />

more here

share|improve this answer
    
Hi Robert, 1 way is to modify the CONTROLTEMPLATES\welcome file. What is on your view of doing this via master page? –  variable Mar 14 at 5:58
    
Hi! Are we talking about building our own control, add the missing control outside of the menu, or something else? I do not really follow (since welcome is already used in master page to render the menu etc) –  Robert Lindgren Mar 14 at 6:06
    
If you modify welcome page then it would apply to entire SharePoint2013 server. However, if one wishes to use the 'sign in as diff user' link on say only one webapplication then, wont it be better option to add it in master page right above the existing signout? And I beleive it is not good practice to touch hive files.. So isnt master page edit a better solution? No one has provided this as an solution. –  variable Mar 14 at 6:09
    
You can provide anything you like as solution :) your approach do require creating at least a copy of the existing masterpage, and edit that one (to make sure nothing gets changed by future updates) though :) my response is focusing on Microsofts approach (run the actual browser as another user), I consider the welcome-modification to be a hack :) –  Robert Lindgren Mar 14 at 6:31
    
OK, I have posted another answer to this question, hope it will help the OP and users... –  variable Mar 14 at 6:32
add comment

There is a free tool from Pointbird that will give you this functionality, or you could just add a custom action that adds a link to "/_layouts/closeConnection.aspx?loginasanotheruser=true"

http://pointbird.com/products/pointbird-sign-in-as-different-user/

http://www.cwheeler76.com/Lists/Posts/Post.aspx?ID=2

share|improve this answer
add comment

Create a bookmarklet that points to :

URL=javascript:window.location = _spPageContextInfo.webServerRelativeUrl.replace(/\/$/, "") + "/_layouts/closeConnection.aspx?loginasanotheruser=true"

As something you deploy to your browser, rather than your site, it approaches the problem from the other direction. But honestly, most of your users won't need this functionality - developers will.

Another advantage of this approach is the same bookmarklet will work in any SharePoint environment, including Office 365.

share|improve this answer
add comment

Your question is about multiple requirements:-

I need to change my current user in my SharePoint site.

How can I change my current user?

How can I add sub menu (sign in as different user) to my menu ?

So, here there are 3 solutions:-

1. Launch your web browser as another user

For IE --> Navigate to C:\Program Files (x86)\Internet Explorer and drag iexplore.exe to the desktop (creates a shortcut) --> Right click your new shortcut and select “Properties” --> Modify the shortcut target by adding runas and the desired user account to the beginning of the path. Change the target to (replace user@domain with your test acct):

%systemroot%\System32\runas.exe /user:user@domain "%ProgramFiles(x86)%\Internet Explorer\iexplore.exe"

Click OK to save changes.

Reference

2. Modify the welcome.aspx page in control templates (HIVE)

Locate the file \15\TEMPLATE\CONTROLTEMPLATES\Welcome.ascx and open in a text editor --> Add the following element before the existing element with the id of “ID_RequestAccess”:

<SharePoint:MenuItemTemplate runat="server" ID="ID_LoginAsDifferentUser"  
Text="<%$Resources:wss,personalactions_loginasdifferentuser%>"  
Description="<%$Resources:wss,personalactions_loginasdifferentuserdescription%>" 
MenuGroupId="100"  
Sequence="100"  
UseShortId="true"  />

Save the file --> Now, the menu item shall be displayed.

Reference

3. Modify the SharePoint MasterPage via Designer or VS module

Open the master page --> Search for <div id="suiteBarButtons"> --> Scroll and paste the below code between the <SharePoint:FeatureMenuTemplate ....> and </SharePoint:FeatureMenuTemplate> tag --> Add the foll. code:

<SharePoint:MenuItemTemplate runat="server" id="MenuItem_SignInAsDifferentUser"
         Text="SignIn As Different User"
         Description="To log in as a different user"
         MenuGroupId="200"
         Sequence="250"
         UseShortId="true"
         ClientOnClickNavigateUrl="~siteLayouts/closeConnection.aspx?loginasanotheruser=true"
         PermissionMode="All" />

This will add the 'sign is as another user' into the site actions dropdown.

share|improve this answer
add comment

Edit Welcome.aspx file in this address :

C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\
15\TEMPLATE\CONTROLTEMPLATES

And then after tag with Id ID_RequestAccess most add this Tag :

<SharePoint:MenuItemTemplate runat="server" ID="ID_LoginAsDifferentUser"   
         Text="<%$Resources:wss,personalactions_loginasdifferentuser%>"     
         Description=" <%$Resources:wss,
                                 personalactions_loginasdifferentuserdescription%>"     
         MenuGroupId="100"   Sequence="100"   UseShortId="true"   /> 

This is my source link. Sign in as different user in SharePoint 2013

enter image description here

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.