Disable lightweight solution load prompt - visual-studio-2017

In VS2017 lightweight solution load is disabled by default and since I don't want it I am happy. BUT there is an annoying prompt which prompts me to enable it when I load a solution with a "Large" number of projects.
Is it possible to disable this prompt, so I do not enable it by accident ?
I have searched Tools -> options and the registry to no avail. Also what is a "large" number of projects I have not been able to find the number. Perhaps if one could raise the number to say 100000 then the prompt would never appear.

The Lightweight Solution prompt is shown three times, per solution, then a setting is stored locally which prevents it being shown again.
From: developercommunity.visualstudio.com: Viktor Veis: 27 Mar 2017:
The lightweight solution message is
shown 3 times per solution. These settings are stored in the suo file,
so deleting the file or the .vs folder next to solution will trigger
another 3 messages.
We're working on improving this experience in a future release.
Beetlejuice! Beetlejuice! Beetlejuice! Sigh

This message do not show again after setting the Lightweight solution load to disabled instead of default.
To do this, select your solution and in the property window (default F4) set the Lightweight load to Disabled
Screenshots here https://learn.microsoft.com/en-us/visualstudio/ide/optimize-visual-studio-startup-time#speed-up-solution-load

Related

How can I disable live code analysis in Visual Studio 2017?

Where can I disable live code analysis in Visual Studio 2017? This pops up every time I start my solution. I do not need this:
I've followed this support document from Microsoft but unchecking "Enable full solution analysis" seems to have no effect on live code analysis. Then I found a solution for Visual Studio 2012 but also without any luck.
So it seems to me that live code analysis is a complete different thing not managed by full solution analysis. It is running immediately as a background process task after (re)starting the solution. Anyway, how can I get rid of this?
It's not possible In VS2017
only if all Roslyn installed components in Extensions and Updates are disabled.
I'm using a workaround, global setting forces analyses runs at build on solution projects, in editor runs at any change but now editor is a lot faster with bellow workaround:
Tools -> Options -> Text Editor -> C# (in my case) -> Advanced -> Perform editor feature analysis in external process (experimental) -> select it and save.
UPDATE: It's possible in VS2019 16.5
More details on closed issue (solution is for VS2019):How to disable live code compilation/analysis in Visual Studio 2017?
I had a similar problem. There is this huge temp initialization file in the project, 50K+ lines. Whenever I opened it, Live code analysis would kick in and VS would eat up CPU up to 50%.
I was able to turn it off by creating an empty rule set and set it on Code Analysis section of the project's properties. Now It looks like it's running, only for a few seconds and then it stops since there is no rule to apply.
I don't know if this exactly applies to your problem but here how it goes.
To create an empty rule set;
Click "Choose multiple rule sets" from the ComboBox under "Run this ruleset" :
Make sure no rule set is checked in the "Add or Remove Ruleset" window.
Click "Save As" button:
In file dialog, save your new rule set. I named mine as "EmptyRuleSet".
After saving process, new empty rule set should be selected in the ComboBox. Click the "Open" button below :
In rule set details, uncheck all the sub rule sets and there is only "None" under "Action" column:
Save the changes on project properties.
After these steps, you can see that "Live Code Analysis" run empty for a few seconds when you open a file or start the solution, then it stops. You may have to restart the VisualStudio.
I was able to make VS 2019 run at acceptable speeds using the 'Auto cancel long running auxiliary operations on typing' setting. The default 'Automatic' setting appeared ineffective, although changing it back now doesn't seen to re-introduce the very slow background processing issue.
I have no idea if this stops/aborts/prevents more useful features, although it seems to "tame" VS 2019's background processing.

Build Order in Output Window Missing with Lightweight Solution Load

I've toggled back and forth between normal solution load and lightweight solution load. In the latter, when I go to the output window, the Show output from dropdown does not have the Build Order view.
Is this a bug, by design (because something about the lightweight-ness prevents this option), or is there something else I need to do to enable it?
I'd like to enjoy the quick load time, but have the build order available when trying to know which error to fix first.
EDIT
On a different solution, Build Order shows up in the dropdown, but during and after a build, the output is empty. Switching back to Build shows that the solution built because the build outputs show up.

Visual Studio 2017 (15.3.1) keeps hanging/freezing

I have recently installed Visual Studio 15.3.1 Community Edition (although I suspect this affects all editions). When doing actions such as
closing SQL .sql file tabs
copying or renaming files
other actions which I can't pinpoint
Visual Studio will freeze or hang for a few seconds or permanantly. It sometimes displays "(Not Responding)" in the title bar, but not always. This is getting really frustrating.
It seems like the Visual Studio feedback system is at fault. Turning it off solved my problem.
Open Visual Studio
Navigate to Help > Privacy > Privacy Settings
Select the "No, I would not like to participate" radio button and click OK
Hopefully whatever bug is causing this issue will be fixed soon and I'll happily participate in the feedback program again!
See this issue posted a lot on the MS forums.
I struggled with it for a while. When editing XAML files, it would always freeze and hang.
Tried many solutions that didn't fixed it. Then, I found the solution that did fix it for me.
I made two changes at the same time, so I can't say for sure which one solved it, but I can guess.
First change, which probably isn't the fix, is that I added the registry keys from this page. They were missing on my system. Page has a lot of detail, but having those keys set properly can't hurt. I noticed in Process Monitor that it was missing on the following regkey:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\Setup\CachePath
Second change I made, the one I'm guessing solved the issue, was deleting the 17k+ ".TRN" files inside the following directory:
%LocalAppData%\Microsoft\VSApplicationInsights\
On my computer they were in something like the following:
C:\Users\Michael\AppData\Local\Microsoft\VSApplicationInsights\vstelXXX_SOMEGUID
Going back to check now, and after three-or-so hours of work there's another 475 files in that folder. It's producing about four or five .TRN files a minute, all with encrypted data inside. Not going to speculate as to the purpose of it, but I doubt it's anything good or useful. Deleted all those, and the XAML editor in VS now works fine, or at least as well as it ever did. No more 30+ second hangs on a modern twentysome core workstation.
In the recent update of VS 2022, the program suddenly starts freezing (randomly) and the fix for me was to turn off inline hints (the thing that pops up when you double click Ctrl key).
I'm using VS for C++ so I turned it off for C++ specifically
Go to the Tools menu tab -> Options

Coldfusion cfprint and UPS labels

I am trying to use Coldfusion CFPRINT to print UPS labels to a network printer. The starting labels (png files) are great and I can print them locally to the zebra printer and they print and work wonderfully. The barcodes produced by CFPRINT however are of such poor quality that a barcode scanner cannot read them. My research shows that Coldfusion uses the jpedal java library which resizes the images to 72 dpi - which is just not crisp enough for a scanner.
I read about using a jpedal setting: org.jpedal.upscale=2 but I have no clue as to where you would utilize this.
Any suggestions on how to fix this CFPRINT resolution issue using Coldfusion?
(Just to add a bit more detail to the comments)
That is a JVM argument. There are several ways to apply it:
Add the setting to your jvm.config file manually. Backup the file first. Then add -Dorg.jpedal.upscale=2 to the end of the java.args section. Save the changes and restart the CF Server. Do not skip the backup step! Errors in the jvm.config file can prevent the server from starting. So it is important to have a good copy you can restore if needed.
Open the CF Administrator and select Server Settings > Java and JVM > JVM Arguments. Add -Dorg.jpedal.upscale=2 to the end of the arguments. Save the settings and restart the CF server.
Again, I would strongly recommend making a backup of the jvm.config file first. As #Mark noted in the comments, some versions of CF have been known to mangle the jvm.config file, which could prevent the server from starting. But as long as you have a good backup, simply restore it and you are good to go.
IIRC, you could also set the property at runtime, via code. However, timing will be more of a factor. Their API states system properties must be set before accessing JPedal. The docs are not clear on exactly what that means. However, the implication is the system property is only read once, so if you set it too late, it will have no affect.
// untested
sys = createObject("java", "java.lang.System");
prop = sys.getProperties();
prop.setProperty("org.jpedal.upscale", "2");
sys.setProperties(prop);
Side note, I was not familiar with that setting, but a quick search turned up the CF8 Update 1 Release Notes which mention this setting "improves sharpness, but it also doubles the image size" and also increases memory. Just something to keep in mind.

Visual Studio 2010 Improperly underlining code/comments with red error line when there is no error

I am working on a rather large project, and I am having strange problems with the IDE in terms of error checking and somewhat with IntelliSense.
Usually if I were to type something boneheaded, like "int a = "aa";", it would underline "aa" in red. However I am seeing VS do this to random parts of my code when I make insignificant changes.
For example:
/*
Some comment here, just going to stretch it out for my example..
*/
int proto1();
int proto2();
If I make changes to other parts of the project, sometimes random functions will get underlined, and even part of a comment. Like just 30 minutes ago it underlined the equivalent of half of that comment beginning in the middle of the word "comment", also it underlined all of int proto1(); and part of int proto2();
I would post screenshots but I am bound by contract not to disclose any work, and I can't easily replicate it in smaller projects.
I don't understand why it does this. When I compile the project, any fake errors and underlining it did goes away and it compiles fine. The point though, is there are no errors. It's making up random errors and underlining random lines/words/half words. I would also like to note that there seems to be a large delay in loading new intellisense information, almost by 2-3 minutes or longer.
I'll try and reproduce it in an unrelated project and post here if I can. However, any help would be appreciated.
Thanks!
*Edit: Forgot to note that hitting the space key several times will on occasion correct the errors however this isn't reliable and does not always work.
Intellisense sometimes can really get stuck with complicated code. I guess until VS2012 release comes out, there's nothing we can do.
There's however one trick that I'm using if this happens - switch your build configuration Debug -> Release and then back again. You don't have to wait, you can just click two times on this drop-down box. It should refresh IS cache and make red error underlines dissappear.
Intellisense is often off, but make sure you have latest updates installed.
I just installed sp1 yesterday and lot of Intellisense issues went way.
I see this is a stale question but some may find this helpful.
I just had this same issue. I tried many of the solutions outlined here and elsewhere. I finally tried running Visual Studio as another user (Shift Right Click Run As Different User) and the issue did not present. I then logged into my computer as another user and deleted the profile of the user I was having the issue with.
If your profile is important to you or there is information within it that is important I highly recommend backing up relevant information first. If you don't understand what information you profile contains make sure you do prior to deleting it.
1) Log in as different user (with admin privileges) than you want to delete
2) Open Properties for Computer
3) Advanced system settings (on the left side)
4) Settings for User Profiles (in the middle)
5) Select the profile you want to delete and click the delete button
6) Reboot
Credit to:
https://superuser.com/questions/63017/how-do-i-delete-a-user-profile-on-a-windows-7-machine-that-is-part-of-a-domain
I had the same issue, and in my case it was mostly related to library functions and types defined in libraries. This one fixed it for me:
Open command line parameters. You can use following to reach there:
Project > ProjectName Properties > Configuration Properties > Linker > Command Line
In the Additional Options box at the bottom add
/I "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include"
You will of course need the correct path where Visual Studio is installed.
Bingo! I hope it works for you too. :)