Monday, September 30, 2013

To interact with SharePoint projects in Visual Studio, your system user account must have administrator privileges.

When I run my Visual Studio 2012/2013 Preview with SharePoint 2013 App the following error shown
"Microsoft Visual Studio

This task requires the application to have elevated permissions.

Why is using the Administrator or other account necessary?
[^] Hide error information 
 [Restart under different credentials] [Cancel the task and return to Microsoft Visual Studio]

Unable to open the Web site 'http://siteapp:420'. Unable to access the IIS metabase. You do not have sufficient privilege to access IIS web sites on your machine."

When I skipped this message and tried to deploy the solution, I following error message was thrown.

"Error 1 To interact with SharePoint projects in Visual Studio, your system user account must have administrator privileges."

To avoid the above problem, please login to your system or development VM using administrator privileged user not with real Administrator or System  Account or localadmin user IDs.

After you logged in with administrator privileged user, hold shift and right click on Visual Studio 2012 and run with other account. Problem Solved.

Hope this helps.

Error occurred in deployment step 'Uninstall app for SharePoint': The local SharePoint server is not available. Check that the server is running and connected to the SharePoint farm.

After a frustrating search results from internet. I though of looking into my Event Viewers. And I found the following error message.

"SQL database login for 'SharePoint_Config' on instance 'SERVERNAME' failed. Additional error information from SQL Server is included below.
Login failed for user 'CORP\MYID'."

I opened the Microsoft SQL Server 20008 Management Studio and given access to the ID in which I am running my Visual Studio. Now it works. Problem solved.

Hope this helps.

Error occurred in deployment step 'Install app for SharePoint': The System Account cannot perform this action.

After different suggestion tried from Internet search I found the following 2 options worked for me.

1) Follow the article steps http://www.codeproject.com/Articles/515677/MyplusFirstplusSharepoint-HostedplusAppplusinplus2

and reset your IIS. It will work

2) This is a security feature in the SharePoint 2013 that you cannot deploy an app using System Account. So what is the alternative?

Create another account and give permissions, so that it is NOT the system account.

So I did the following: •Created a new account in AD as “admin1”
•Added “admin1” account into Farm Administrator’s group in Central Admin
•Added “admin1” account as Site Collection administrator to the target developer site
•Added “admin1” account into local administrators group

Ref:

To "Run as different user" using Context Menu
1. Press and hold the Shift key and right click on the program's shortcut or BAT, CMD, EXE, MSC, or MSI file, then click/tap on Run as different user. (See screenshot below)
Name:  Context_Menu.jpg
Views: 5775
Size:  51.6 KB
2. Type in the user name and password of the user account that you want to run this program as. (see screenshot below)
NOTE: If the user account is on a domain, then you would use UserName@Domain or Domain\UserName for the user name instead.
Name:  Log-On.jpg
Views: 7368
Size:  61.2 KB
3. If prompted by UAC, then click/tap on Yes.

4. The program will now be running as that user.

5. When done, simply close the program to stop it from running as that user.


Helpful Post  ref: 
http://www.sevenforums.com/tutorials/419-run-different-user.html
http://blog.mannualag.com/2013/03/07/nuisances-of-starting-developing-apps-for-sharepoint-2013/
 

ASP.NET MVC - Sport Facility Booking system

  The project relies on some external service providers. Thus accessing them via their API requires authentication. An API Key need to be su...