Prevent VS2017 from connecting to SQL database - dialog

I am working on a ASP.NET MVC project in Visual Studio.
Since today I see am seeing every now and then
a dialog window "Connect to SQL Server" that uses {0} as user name:
I always click Cancel as the user name is just a place holder. It is read - as the rest of the database configuration - from Web.config.
The documentation just states:
This dialog box appears when specific access permission is required
for the current database process.
I believe I do not need this access. How can I prevent Visual Studio from showing this dialog?
PS: I do not want to remove the configuration from Web.config as it is needed by my project.

After a little debugging, it turned out that it was the awesome Meene VS Tools 2017 extension which caused this problem. Specifically, the Enable tasks provider option. Just disabling it helped to get rid of the nasty dialog. Maybe one could also add the Web.config to the Excluded file name patterns to fix the problem. Since I do not use the tasks, I did not try though.

Related

"Communication with the SharePoint server is Cancelled" error when building SharePoint hosted addin

Last month, I had a Sharepoint addin installed into a clients Project Web Access (pwa) server working quite well.
This month, when I try to compile and run a new version of that same project in Visual Studio, I'm getting a popup asking "Do you want to switch the project to Offline mode?" and if I say 'No', I get a "Communication with the SharePoint server is Cancelled" error when uploading my project.
There have been no configuration changes. The only code changes were to a .JS file (and we reverted those changes, just in case).
There may have been updates to Visual Studio during that time.
I have...
Ensured that the server name is correct and unchanged.
Ensured that the 'Server Connection' property for the project is 'Online'
I can't find any useful diagnostic information anywhere.
Does anyone have any suggestions about how to resolve this, or at least how to get some diagnostic information about why it's happening?
It appears that Office365/SharePoint Online has new defaults that prevent access from external applications ( I was also unable to connect via PowerShell scripting using my Sharepoint Online credentials).
I updated the settings under Policies|Access Control in the Sharepoint Online admin console to allow connection, and now I can connect from PowerShell, and I've got a different issue in Visual Studio.
While I still don't have diagnostic information about communication problems, I've managed to get a little further.

Missing custom screen in Acumatica customization project

I’m experiencing an issue with customization projects in Acumatica 2017 R2 Build 17.203.0029.
Specifically, custom screens, while in my project XML, are not visible within the customization project browser nor can they be navigated to once published (which occurs without error). This only occurs on my staging server. Everything works fine in my local dev environment and even on a different instance of Acumatica. My local dev environment matches the staging server in every possible way (Acumatica version, other packages, etc.)
Older versions of the same customization project have been published before and did not exhibit this behavior. It’s only after I replaced the project with newer version of the same project that I encounter the missing custom screen issue.
As shown in the screenshot below, remnants of the custom screens are present in the Customized Screens window. And the ASPX files are present and shown in the Custom Files window.
Screenshot of missing custom screen data
When I compare the “Edit Project Items” objects between the staging the server and my local dev version, they appear the same.
It it possible that the internal customization or sitemap tables on the staging server have inconsistent data? Is there anyway to rebuild them?
The solution appears related to the users roles config. I had not assigned access rights to the custom forms. Doing so solved the issue. The custom screens are now accessible by direct URL and are shown in the customization project browser. Maybe this will help someone else.
I had this same issue when trying to Deploy the customization to another instance.
To fix it I had to go to the site manager and change the URL of the new page
from: "/Pages/SO/CustomName"
to: "~/Pages/SO/CustomName"

Error when trying to deploy webpart

I've been searching on Google for a resolution to this problem, but cannot find one that matches yet.
I'm trying to deploy a simple "Hello World" web part to SharePoint using Visual Studios 2010.
I'm getting an error when I hit F5: "Error occurred in deployment step 'Retract Solution': Cannot connect to the SharePoint site: http://example.com/. Make sure that this is a valid URL and the SharePoint site is running on the local computer. If you moved this project to a new computer or if the URL of the SharePoint site has changed since you created the project, update the Site URL property of the project."
Ok, I have done a lot of searching and I'll tell you what I've tried so far. I have full admin rights on the farm, full rights to both databases. I made sure the webpart URL property matches the site property listed in Central Admin as well.
If anyone has any advice or insight it would be greatly appreciated. Thank you in advance.
P.S. (Edit) Also, the farm I'm deploying to and visual studio are on the same machine? would that cause it?
Check the properties of your project in Visual Studio. Click on project node in solution explorer and press F4, then check there 'Site URL' property. It should contains one of the following
http://[your machine name][:port]/[site collection or web relative URL]
http://localhost[:port]/[site collection or web relative URL]
http://[your machine IP address][:port]/[site collection or web relative URL]
Note that Visual Studio must be installed on that machine which is your Web Front End or Application server.
If you got some errors with solution retracting try first deactivate and delete it via Central Admin. Then try to make some deploy-retract checking cycle in Visual Studio. If you still would get errors please post here the log from Visual Studio Output window (Ctrl+W, O).
I was able to go ahead and deploy the web part using STSADM commands from tutorials that you guys referenced in this topic, thanks so much for that.
It seems the problem I'm having involves multi-server install, and I don't think there is a quick work around yet.
Thank you all for the responses!
Follow below mentioned steps to debug this issue :
1) Browse the URL in IE on your server where you have hosted the http://mysite.com site.
2) If you are able to browse then try deploying this web part on another site by giving new site URL in project properties in Visual studio.
3) To deploy a solution onto a site you must have visual studio on the same computer where you hosting the site.
4) Try deploying WSP through stsadm, Click here to see the details. To create WSP in Visual studio right click on project -> click on 'Package' -> once its complete right click on project -> click on 'Open in windows explorer' -> open 'bin' directory -> open 'Debug' directory -> you shall see a file named as your project name & extension would be .wsp
5) If anything above doesn't help put down your deploying steps.
Please do the following
Can you first verify the Site Collection you are trying to deploy is working or not
Open the properties of the SharePoint Project >Properties(F4)> Build Tab and see that the platform has been set to Active(Any CPU).
Delete the Solution from Central Administration and then try to deploy the solution once again.
If you still have the same problem then attach the log file from the SharePoint logs.
Thanks,
-Santosh
Have you mention the Site URL property in Visual Studio Sharepoint project?. you can open using (ctrl+shift+p) for Window of Properties then Check project Properties and make sure Site
URL is the Web application where you want solution to be deployed.
might be helpful this link: http://www.dev4side.com/community/blog/2010/2/28/error-occurred-in-deployment-step-%27recycle-iis-application-pool%27.aspx

Sitecore crashing application pool when using Security Editor on a specific role

Starting today, whenever I try and use security editor on either of two similar roles I get a timeout. If I try again IIS reaches an error threshold of some kind and stops that Application Pool. Then all of our users receive a "Service Unavailable" message from IIS.
I can edit other roles. This error can be recreated.
I assume I have some kind of database corruption, but I can't find an error that helps me in Event Viewer or the Sitecore logs. Where else can I look for more detail?
IIS6, Windows Server 2003, Sitecore 6.2
It sounds to me like you've got a circular reference in your roles.
Are you using the default role provider, ASP.NET membership? If so, try using the default Microsoft security tools (you can get at 'em via Visual Studio). If that doesn't work, you can programmatically modify these roles using the API.
Also, I believe there is a known issue which may be fixed in a 6.2.x update. I would check the change list at SDN. Here: http://sdn.sitecore.net/Products/Sitecore%20V5/Sitecore%20CMS%206/ReleaseNotes/ChangeLog.aspx
Yep... take a look at the 6.2.0 rev 100701 update list.

SharePoint COMException

When adding or editing a page in a SharePoint Pages library we get the following exception:
[COMException (0x81020016): Item does not exist
The page you selected contains an item that does not exist. It may have
been deleted by another user. Click "Home" at the top of the page to return
to your Web site.]
at Microsoft.SharePoint.Library.SPrequestInternalClass.RenderColumn.
The weird thing is, when we first do "Check in" and then click the Publish button it works perfectly. But clicking "Publish" directly generates theis error, BUT NOT ALWAYS!
The Pages library has publishing and item planning on, NO workflow (seeing as the person who adds / edit pages is also the approver) and Major/ Minor versions.
We use a content type derived from publishing page and a custom PageLayout.
I'm sure you would have already checked this but is there any more information in the ULS logs?
Also have you tried setting the debugger to break on all exceptions and does this give you more information? Go to Debug, Exceptions and tick Common Language Runtime Exceptions. Then go to Tools, Options, Debugging and untick Enable Just My Code. Finally attach to w3wp.exe.
If you are running Windows Server 2008 you could also try taking a dump file at the point the debugger breaks above. ADPlus might help if you are running Server 2003 but I don't have experience with it. You should then be able to open the dump file with DumpChk or WinDbg.
Edit: As discussed in the comments, this is code deployed to production that can't have its service interrupted. The only way you could create a dump file is programmatically. Have a look at this question I asked that will hopefully help you if you need to go down this route.
Other things to try if you don't want to get down and dirty with debugging is to try deploying your custom bits to a clean server. See if you can still reproduce the problem or if it changes.
I am assuming that you are using load balancing with 2 web servers.
The fact that it does not happen always points to there being a difference between the servers.
There are then a few things that you could check:
Are all the versions and service packs are the same on both machines
Have any of the servers had beta software installed
Is your code the same on both servers
One thing you could do to test without taking the system down: Is to remove the first web server from the cluster see if the error occurs, then add it back and do the same thing with the second web server.

Resources