My Problem
In Microsoft Visual Web Developer Express 2010, my intellisense suddenly stopped working today for my front end HTML (.aspx) files but is still working fine for code behind (.cs) files.
Along with this, when I hover over any asp control declared in my aspx pages, it says
validation(): Element 'control' is not supported.
validation(): Element 'label' is not supported.
etc...
(side note: 'control' and 'label' are lowercase in the message, instead of the proper case)
My Progress
I have been looking around for answers,
a few people suggested deleting certain files, such as the "*.ncb",
but I have not been able to find any MS files with this extention
anywhere (hidden files are visible).
I have a "Web Site", not a "Project" so within my site there are no
*.sln", *.proj, *.suo" files to delete either.
One suggestion was to "Clean" my project, but I can't find that
option anywhere.
Another person suggestion running "MS Developer command prompt" and
executing a utility called "devenv" with certain arguments. I do not
have the "MS Developer command prompt", I assume because I am using
the Express Edition. I cannot find the devenv utility in my file
system as well.
I have checked all my master pages but haven't noticed anything
weird.
I looked in the Tools > Options menu but didn't find any "intellisense" type of thing anywhere. My "Show all settings" is turned on.
I tried changing the doc type in the dropdown from XHTML 1.0 Transitional to all the other things just to see, with no luck.
My Plea to fellow .Net-ers
My website builds just fine with no errors, it's just having no intellisense on my aspx pages is driving me nuts.
Is there anything else I can try? Any thoughts appreciated. Thanks!
OK,
DevEnv is the program name for visual studio - it will be here:
"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe" on a 64 bit OS
or
"C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe" on a 32 bit OS.
Right click on the icon you use to run VS and then click properties and it will tell you where this file is in the Target box.
To clean a project, right click the project in the solution explorer and then click Clean.
Visual studio command prompt will be in the start menu under:
Microsoft Visual Studio 2010 > Visual Studio Tools
There may be several version depending if you are running on a 64bit OS, Itanium, etc. You can also just run DevEnv from the Run box or ordinary command prompt.
The 32bit version can be run from the Run Box using the following (if on 64 bit, add " (x86" after "Program Files"):
%comspec% /k ""C:\Program Files\Microsoft Visual Studio 10.0\VC\vcvarsall.bat"" x86
Personally, after closing down VS and rebooting the machine to check if it was just a process crash causing it (i.e. restart from a fresh OS and VS load) - I would reset option (see here /ResetSettings (devenv.exe)).
Good luck, and please reply back mif this worked or did not so to give the thread a conclusion. :D
Related
Our previous development systems used Windows XP and Windows 7. Debugging C++ DLLs from Visual Studio worked great.
A recent move to Windows 10 has resulted in an annoying problem. We can debug once (using F5), but the 2nd time results in a linker error:
MyProg fatal error LNK1201: error writing to program database 'MyProg.pdb'
Trying to delete the .pdb manually in Explorer while Visual Studio is still open results in the error:
The action can't be completed because the file is open in devenv.exe
It doesn't matter whether you hit a breakpoint or not. Just start debugging once results in the problem. Re-starting Visual Studio resolves the issue (in the sense that you can debug once, but then you get the problem again).
If relevant:
x86 Visual Studio 2003.NET
targeting another x86 application
x64 Windows 10 Pro v1803
After hunting around for several hours some related, but unanswered, questions were found. Following suggestions in this MSDN article, along with some debugging of my own, this solution works:
Download FreePDB, a script written by MSDN user Toni76 (thanks Toni!)
Copy this script to a local folder (say C:\Apps\FreeDPB)
Download the latest version of SysInternals tool Handle (currently v4.21)
Copy handle.exe to C:\Apps\FreeDPB
NB! From the command line, run handle /? once. This is to agree the EULA. The script will not work if you skip this step!
Open Visual Studio, then Project > Properties > Build Events > Pre-Build Event
Set Command Line to C:\Apps\FreeDPB\freepdb $(ProjectName)
Set Description to Delete lock on PDB
...and now you don't need to restart Visual Studio to debug a 2nd time!
From comments, this works with multiple versions of Visual Studio on multiple versions of Windows.
Update
A more radical solution is described here which involves replacing a core Visual Studio DLL (NatDbgDE.dll). This solution only works for Visual Studio 2003 SP1, though.
In my case it was due to "Process Explorer" program, which was open alongside with my Visual Studio(I used it to check some properties of the exe I've created). After closing it problem solved.
We have installed Visual Studio 2015 Professional on Windows 7. It was working fine. But after we installed updates from the menu Tools-->'Extensions and Updates' today the Visual studio does not start anymore. we tried using 'run as administrator' as well. From the Start menu we right click on 'Visual Studio 2015', then 'run as administrator', the usual dialog box asking for permissions appears, we click on 'Yes', splash screen for Visual Studio appears for a second and then disappears. On the Task Manager, it does not appear as well.
Re-starting the system does not help either. .NET 4.6 is installed and Visual Studio 2012 on the same system is working fine.
UPDATE 1
The issue started after we installed the last update (from within VS2015) that had something to do with universal apps I think.
UPDATE 2
At the exact time when I start VS2015, one Windows Event log gets generated under security section as follows:
EventID 6281
Microsoft-Windows-Security-Auditing
Audit Failure
Message: Code Integrity determined that the page hashes of an image file are not valid.
The file could be improperly signed without page hashes or corrupt due to unauthorized modification.
The invalid hashes could indicate a potential disk device error.
File Name: \Device\HarddiskVolume3\Windows\System32\l3codeca.acm
I had the same problem recently after I upgraded one of the packages. I tried "everything" and the only option that worked was the /Setup switch (I was logged in as Administrator, but don't think that's required).
c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>devenv.exe /Setup
c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>devenv.exe
https://msdn.microsoft.com/en-us/library/ex6a2fad.aspx
Here's what worked for me.
Go to the Command Prompt and navigate to the folder with devenv.exe
In my case it was C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE
then execute
Devenv.exe /ResetSettings
https://msdn.microsoft.com/en-us/library/ms241273.aspx
I had the same problem. It was caused by Visual Studio Extensions adding paths to $PATH, which made $PATH grow too long (>2048 bytes).
This breaks VS and lots of other stuff on your machine.
Removing outdated and duplicate lines from $PATH made it short enough and VS2015 and everything worked again.
If nothing above works (like in my case) then open a registry editor, go to HKEY_CURRENT_USER\Software\Microsoft\VisualStudio and delete all 14.0 directories.
It will reset all VS settings and next launch will be like first one after installation.
Found answer here
After trying the other solutions in this thread, what finally worked for me was:
From an elevated Command Prompt, navigate to "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE".
Execute:
devenv.exe /Log C:\temp.log
https://msdn.microsoft.com/en-us/library/ms241272.aspx
The log should contain a matching set of Begin and End entries for every extension:
<description>Begin package load ...
...
<description>End package load ...
If the last extension is missing the End package load entry, you need to uninstall that extension.
Execute:
devenv.exe /SafeMode
https://msdn.microsoft.com/en-us/library/ms241278.aspx
Go to "Tools -> Extensions and Updates" and uninstall the offending extension.
Exit VS. Start VS as normal. In case it still doesn't work, repeat the procedure.
Nothing of above helped me, What helped me was to copy devenu.exe from other computer which had VS installed and then replacing it with mine computers devenu.exe.
Run C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Blend.exe
Right click on some file in "Solution Explorer" such as "default.aspx" and select "Edit in Visual Studio"
For me it only shows Visual studio 2015 window without disappearing and showing IDE or any error.
Non of following solutions worked for my normal domain user but there was no issue running it with administrator.
Devenv.exe /ResetSettings
Reinstalling
Repairing
Watching event viewer for more details
Cleaning temp and cleanup and finally seeing some error
Finally I deleted my whole profile from admin via [System properties]-> [Advanced] -> [Profile] and it resolved the problem.
Just before that copy your user folder somewhere or at least your desktop and user folders and also your bookmarks and settings.
I tried several methods above and even re-installed VS but it did not work. The final solution was to really completely remove all the settings and registries of VS with the tool VisualStudioUninstaller. After uninstalling and re-installing it, it is up again.
First of all, I am not asking the same question here. ( This may be a duplicate post on Stack Overflow.) I have searched other solutions on MSDN, ASP .NET Forum, Stack Overflow, Code Project and everywhere on internet. But none of them solved my problem. These are the links that I found:
http://blogs.msdn.com/b/kirillosenkov/archive/2012/01/11/vs-hangs-for-1-minute-on-start-debugging-check-for-dead-symbol-paths.aspx
http://www.codeproject.com/Questions/272109/Visual-Studio-2010-Hangs-When-Debugging-App
And a lot more...
My CPU is 4th Generation Intel Core i7 and memory capacity is 8 GB. I think it is more than recommended hardware requirements.
Problem:
My visual studio hangs on these situations.
Opening a solution (Hangs for a minute when I open a file from solution explorer)
Running the debugging (Freezes consistently when I click on debug button) and
Stopping the debugging (Freezes immediately after the UI returns to the Developer layout after debugging)
I have tried the following steps:
I ensured that I deleted all the breakpoints in the solution.
I ensured that I am not using any resources from network drive.
I ensured Step over properties is enabled.
I ensured Enable .NET Framework source stepping is NOT enabled.
I start visual studio with SafeMode to suppress extensions
I cleared watch window.
I cleaned and rebuilt the solution.
Before I encounter this problem, I installed "Install Web Components" Visual Studio Add-In a few weeks ago. May be because of extensions and add-ins?
How can I do it to solve my problem?
If you suspect that Visual Studio settings get corrupted after installing "Install Web Component" bundle, why don't you try to reset the settings?
You can perform the steps below to reset Visual Studio settings:
Open Visual Studio Command Prompt (2010) under Start menu > All Programs > Microsoft Visual Studio 2010 > Visual Studio Tools (Run it with Administrator privilege: Right-click the program > Run as administrator)
Run devenv /Resetsettings to restore the IDE's default settings, optionally resets to the specified VSSettings file.
Run devenv /ResetSkipPkgs to clear all SkipLoading tags added to VSPackages.
Run devenv /Safemode to see if you can apply it correctly. This can eliminate the possibility that third party Add-ins or packages are causing problems.
Open your solution in Safemode and see whether it works.
Found this to happen also when the solution is connected to a Team Foundation Server and the service is not available at the moment, so the solution could not connect. In this case do not end the Visual Studio instance and wait until a message box show up giving the option to Go Offline. This is usually associated with the "Visual Studio is waiting for an operation to complete...." notification message.
My solution was simply to reload a saved GOOD (backup) copy of my settings (made a year ago). Worth trying before resetting everything to blank. My VS2010 would take 60 seconds to start debugging and approx. 3 minutes to stop debugging. I saved the corrupted settings and to my surprise they were over 3MB instead of 260Kb. I loaded the good backup copy and everything is great again :-)
If Visual Studio doesn't respond only when attempting to open solutions, then open a raw instance of Visual Studio then Reset Settings
Check How to: Reset Your Settings from the Tools Menu
http://msdn.microsoft.com/en-us/library/ms247075%28v=vs.90%29.aspx
This is Visual Studio 2013 and Windows 8.1
Open developer command prompt.
Start -> All programs -> Visual Studio -> Visual studio tools -> developer command prompt
Make sure that you don't have any pending changes that need to be checked in.
run this command : "tf workspace /delete 'your workspace/ machine name'"
yes for removing the unnecessary pending changes if at all present.
I have downloaded and installed Microsoft Visual Studio 2010 Express for Windows 7 Phone. Problem is that i cant see "Silverlight for Windows Phone" option when I right click my Project name and select Add -> New Item option. I can only see "XNA Game Studio 4.0" under "Visual C#" category.
I have tried installing Silverlight SDK separately by downloading it from Microsoft site but the installer tells me that i have already installed the newer version of the SDK. Due to this problem I can't use few Silverlight classes like ChildWindow etc.
Can anyone please help me in this regard?
I personally haven't had problems with the WP tools install, but I have witnessed others having problems. The only advice I can give is to uninstall all the tools, sdk, etc and reinstall with the latest.
It's a pain, but might be necessary unless someone has a better idea.
The instructions at http://msdn.microsoft.com/en-us/library/ff402526(v=VS.92).aspx say
Make sure you have downloaded and installed the Windows Phone Developer Tools from the App Hub.
So my advice is to make sure you've done that.
Right having just struggled with this myself I finally found an answer.
If you have a Full version of Visual Studio installed it will not install the templates to the Phone version of C# express (turns out it is actually a different executable to the standard C# Express, go figure)
So to resolve this you need to do a couple of things:
Snippets
First, add the path to the Snippets in the snippet Manager using "Tools -> Code Snippets Manager"
Click on "Add" and enter the following Path:
C:\Program Files (x86)\Laurent Bugnion (GalaSoft)\Mvvm Light Toolkit\Snippets\CSharp\
(Note ignore the (x86) if you are on a 32bit system)
This will install the installed snippets into VS Express.
Templates
Now this is a little more tricky but bear with me
Copy the MVVM folder from:
C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\ProjectTemplates\CSharp\Silverlight\
To
{Documents Folder}\Visual Studio 2010\Templates\ProjectTemplates\Visual C#\
(Replacing the {Documents Folder} section with your My Documents folder)
Repeat the above replacing ProjectTemplates with ItemTemplates
Finally!!
To finish this off you have to tell VS Phone Express to actually install the templates
Run a Command Prompt with administrative privileges (either create a command line short-cut on the desktop and right-click run it with admin privileges or use the VS tools command prompt)
Run the Following command in that window
"c:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\VPDExpress.exe" /installvstemplates
(Note ignore the (x86) if you are on a 32bit system)
If all goes well you should see nothing happen :D, but if you run VS Express for Windows Phone now you will have the new templates installed and the item templates plus the all useful code snippets
Hope this helps!
I have Visual Studio 2008 and 2010 installed side by side, but trying to open either a 2008 or 2010 sln file results in nothing. The hour glass comes on for about a second and then it goes away and nothing is opened.
I read somewhere to relate sln file to VS directly, but I can't go that route because I don't want 2008 solutions to open with 2010. Does anyone know what the problem might be and how to fix it?
If you are running Vista or Windows 7 with the UAC enabled and have "Run this program as an Administrator" checked on the Compatibility tab for the Visual Studio exe (devenv.exe), you will get this behavior when you try to open a sln file directly from Windows Explorer.
One solution is to go to "%ProgramFiles%\Common Files\Microsoft Shared\MSEnv" or ("%ProgramFiles(x86)%\Common Files\Microsoft Shared\MSEnv" for 64-bit systems) and right-click VSLauncher.exe and select Properties. On the Compatibility tab, check "Run this program as an Administrator". Now when you try to open a sln file directly from Windows Explorer, you will get the elevation prompt and it will open the correct version of Visual Studio for the file.
Apparently, the "run as administrator" hack does not work anymore in Visual Studio 2010 SP1. Fabian describes a workaround here:
Getting Visual Studio 2010 SP1 to run elevated when launching .sln files
To sum it up:
Backup VSLauncher.exe
From within a Visual Studio 2010 Tools prompt, extract the manifest from VSLauncher.exe:
mt -inputresource:"VSLauncher.exe" -out:VSLauncher.exe.manifest
Alter the VSLauncher.exe.manifest file:
<requestedPrivileges>
<requestedExecutionLevel level="requireAdministrator" uiAccess="false">
</requestedExecutionLevel>
</requestedPrivileges>
Write back the manifest into VSLauncher.exe:
mt -outputresource:VSLauncher.exe -manifest VSLauncher.exe.manifest
The really annoying thing about this problem is that you have to run Visual Studio as administrator under windows 7 to attach to an IIS instance. The least they could do was not break the .sln files when you do that!
The post by Jorge Poveda is correct though, the original hack no longer works but his does. It's maybe worth mentioning that you have to run everything as administrator for it to work (the command prompt and text editor).
I think there is a better way though as we have Win 7 at work which runs as administrator and didn't have this issue. The key difference is that with this fix, the admin prompt asks you to open VSLauncher.exe, but on my work machine, it asks to open devenv.exe so VSLauncher must be OK to open VS2010 somehow. I'll ask our infrastructure guys how they did it and post back.