TypeScript installs incorrectly - syntax-highlighting

I installed Visual Studio 2012 Express followed by the TypeScript plugin.
I launched VS and noticed that my .ts files are not getting any syntax highlighting.
I did not have any of the project templates relating to TypeScript, nor the Tools->Options->Text Editors->TypeScript settings.
I even tried to uninstall/re-install everything. Nothing worked.

I was desperately looking for a solution and it seems like none exist, so I decided to post the solution that worked for me.
It could be a complete fluke, but I thought I'd share it anyway, in case it can help someone else.
I have Windows 8 installed, but I don't think that's a factor since my other PC works just fine with Windows 8 + VS 2012 Express + TS plugin.
I went into C:\Program Files (x86)\Microsoft SDKs\TypeScript\0.8.0.0 and with VS closed, I ran the TypeScriptLanguageService.vsix file.
HTH

You did find the appropriate work-around.
One known issue with the installer is that if your "documents" path is on a network share, the VSIX doesn't get installed automatically. Is that the case for you?

Related

Visual Studio and/or Windows Explorer Crash with TypeScript Files

In Windows Explorer, whenever I try to open a folder that contains TypeScript files, explorer freezes and crashes. When I try to edit TypeScript files in Visual Studio, it allows me to do so until I save the file. When I save the file, Visual Studio crashes without any dialogs.
I tried completely removing anything Visual Studio related (uninstall, registry clean, etc.) and reinstalling. I also tried running Windows in safe mode, and/or running Visual Studio in safe mode, none of which work. Running Visual Studio as an administrator also does not work.
I know it is not an issue with the actual repo since these files work fine on several other developer machines. This functionality was working just fine a month ago, with no changes in updates or installed extensions.
I am running Visual Studio 2015 Update 3 (14.0.25431.01) on a Windows 10 64-bit machine. TypeScript Tools for Visual Studio is at version 2.2.1.0.
Please let me know if there are any logs I can provide, I'm not sure where to get them.
The following update fixes this issue:
Cumulative Update for Windows 10 Version 1607 for x64-based Systems (KB4015438).
This is as of March 20, 2017.
UPDATE:
Many people have reported this issue as being the result of Windows Update KB4013429. This affects all Visual Studio installations. To resolve the issue, simply uninstall this update and restart your PC.
Old "Solution":
I solved the problem by reinstalling/cleaning Windows.
I know that's not a very good answer, but I wasn't able to solve the issue otherwise. Disabling antivirus shields did not work, and neither did running in safe mode. I think something in the registry may have gotten corrupted during a Visual Studio reinstall. Would love to hear any actual solutions if anyone else comes across this problem in the future.
I deleted a lot of stuff in the Registry under HKEY_CLASSES_ROOT\.ts, and now I can at least view folders in Explorer that contains .ts files, but I still cannot right-click them.
The biggest problem for me and my colleague was that Git and Visual Studio was unable to overwrite .ts files sometimes ("permission denied"), and we couldn't delete them manually either.
I'm not quite sure this has solved the problem permanently for me, but it seems so at the moment:
I used Handle to determine that SearchProtocolHost.exe had locked my .ts file, and wouldn't release until a few minutes later.
A few Google searches later, and I have now disabled indexing .ts files in Windows Search. So far, no more locks!

"Please correct before proceeding." - Web.config error

I attempted to launch a website project locally but received the below message in an error dialog:
Please correct before proceeding.(You might rename the current web.config and add a new one).
Typically this error is preceded by a general description of the cause, this one was not. Knowing odd, out-of-the-blue, problems such as these are typically related to corrupt IDE generated files. I tried deleting the .suo, .vssscc and other generated files from the solution and project directories but the problem continued.
This happened to me today after getting latest. I resolved by closing and reopening the solution, rebuild, then run. All is well...
I actually resolved this by making sure the Web.config file wasn't an open document inside VS 2015. In other words, close the Web.config file wherever it might be open, and make sure your Team Explorer isn't causing any problems, like an unexpected change or staged change...rebuild the sln and run...
Close vs2017 and open it again worked for me
just open web.config and run again.I've had this problem and I resolved by this solution .
I fixed the problem using a solution I found for a different IDE-related issue (original answer here). Run the following in an elevated command prompt:
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.exe" /setup
Note: You'll need to adjust the path for your version of Visual Studio (original version mapping answer here):
Visual Studio 2005 = 8
Visual Studio 2008 = 9.0
Visual Studio 2010 = 10.0
Visual Studio 2012 = 11.0
Visual Studio 2013 = 12.0
Visual Studio 2015 = 14.0
This issue came to me after merging some code in version control using RTC tools. When I saw whyoz answer I noticed that web.config wasn't opened anywhere. It could be RTC locking the file or something like this. So, I simply restarted Visual Studio and it became normal again.
I ran into this issue today after doing a branch merge using the VS19 built-in Git tools. The config file was correct; I even used a schema validator based on KD2ND's answer in how can I validate dot net application config file(ex, app.exe.config) on console?.
I cleaned the solution, unloaded it, and reloaded it, and everything worked fine. I didn't even need to restart studio.
Based on others' answers, this appears to be related to code merging in the IDE. It's a weird problem but it's a relief that the solution (once found) is simple.
As an FYI, in VS 2019 the solution is to close the tabs, and the solution and Visual Studio, then restart Visual Studio. This has worked for me.
in Microsoft Visual Studio 2019 : Just neeed to close project, thenn open+ clean+rebuild and everything work
In VS 19 Enterprise, the Solution for me was:
"C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\devenv.exe" /setup
Based on the merked answer from alan.
I had just opened the web.config file and then pressed CTRL K + D. it will make the formatting good of the file. and then run the application. it worked for me.
Even if you undo the above changes then also it works. it is weird somehow.

Visual Studio 2013 Search Solution Explorer fails to find files

So, I was using Visual Studio 2013, it crashed, and when I restarted it the Search Solution Explorer had stopped functioning correctly:
It fails to find any file if you type in the exact file name
It fails to find any static files e.g. HTML, CSS, JavaScript, etc.
It fails to find any configuration files e.g. Web.config
It seems to still find some files on a partial match, but not all files that you'd expect it to match e.g. if I search for Account I'd expect it to find AccountController.cs and AccountControllerTest.cs but it only finds the latter.
Some further info:
If I start VS 2013 in safe mode Search Solution Explorer works fine without any problems
If I manually disable or uninstall the extensions I'm using and start VS normally, the problem with Search Solution Explorer reappears
Has anyone come across anything similar to this, or got any suggestions of what to try to get Search Solution Explorer working again?
Update
I've had some joy running devenv /ResetSkipPkgs and devenv /ResetSettings. After a I ran those command Search Solution Explorer started working again, and works most of the time now. It still fails occasionally. Sometimes restarting Visual Studio will get it working again, but sometimes it just plain refuses to find certain files that are there.
Update 2
I installed Visual Studio 2013 Update 2, and Search Solution Explorer ran without any problems for just over a week before this problem reappeared. Restarting Visual Studio got Search Solution Explorer working again.
I was able to narrow this down to the extensions I was using, "Productivity Power Tools 2013" seems to break the search feature for me in IIS, so I've disabled it for now. I'm getting a full set of results when searching now.
I came to this conclusion by uninstalling all of my extensions and reinstalling them one by one until the problem reappeared.
A coworker also had some success with this solution, launching DevEnv.exe with /ResetSkipPkgs
http://msdn.microsoft.com/en-us/library/ms241276.aspx
Update
The problem returned for me after about 30 minutes, no specific cause noted. It was nice while it lasted. Removing all extensions gets me the same behavior as OP, only running in safe mode appears to work.
Deleting the .suo file also seems to fix the problem for a while, and then it comes back. I'm about to resort to a reinstall of vs2012 just to get this search feature back.
Please try to install VS2013 update 2 CTP before reinstalling everything and see if it fix the bug:
Weird that it works in Safe Mode, or that you manage to fix by removing extensiosn and it then re-appears...
but if some of your projects are in solution folders, then there is a known bug, fixed but not released yet apparently:
http://connect.microsoft.com/VisualStudio/feedback/details/801836/solution-explorer-doesnt-search-files-projects-inside-solution-folders
I have the same issue and confirmed it related to VS2013 Update 2 RC. Uninstall it will fixed this issue.
Wait for GM version of VS 2013 update 2.
I still had this issue both prior to and after installing VS update 3. I should note that it went away after I installed that for a while, and then came back. I suspect (but cannot confirm) that the broken behavior's return coincided with a lockup of my system which necessitated a reboot...
Anyway, I had the Productivity Power Tools installed, and after reading the answers here wondered if it might be complicit, and so I went to disable it and noticed it had a pending update. I went ahead and updated the add-on, and that resolved the issue for me (again). We'll see if it stays fixed.
This may caused by other extensions you have installed in your visual studio. I have some issue, found out Telerik JustTrace caused this issue.
Running devenv /ResetSkipPkgs will fix the problem but, as noted, it will return. For a permanent solution, add this parameter to the target in the exe's properties:
"C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe" -ResetSkipPkgs

"Csc.exe" exited with code -1073741819

Everytime I try to run my code, I am having this error that "Csc.exe" exited with code -1073741819
, I cleaned my solution and restarted Visual Studio with no gain.
Can anyone help me?
I faced same problem. Delete the bin and obj folder in project(s). The try to clean and rebuild the solution. This worked for me.
Cleaning and rebuilding the solution will sometimes solve the issue and sometimes won't.
You need to repair Visual Studio. Go to Control Panel -> Programs. Then select your version of Visual Studio you are using and press "Change"(or right click it and press "Change"). When the setup appears, click "Repair".
This solved it for me and several others who have been facing this issue.
For the problem csc-exe-exited-with-code-1073741819
I repaired Visual C++ 2015 Redistributable (x86). This worked for me.repair Visual C++ 2015 Redistributable. I found about this problem when uninstalling and then reinstalling VS2015. After the setup is completed it says that some items are not installed correctly. And among them is Visual C++ Redistributable for Visual Studio 2015 not installed correctly.
So after a while I repaired Visual C++ Redistributable 2015. Here is the link Visual C++ Redistributable for Visual Studio 2015.
classic ms solution: restart computer :D
delete bin and obj folders
open vs
build
it should work.
I want to share my experience here because I had this problem for several days (with VS Studio 2012) and I had MANY MANY difficulties to find the solution !
And my problem was... That I had a virus/malware problem, and the faulty module was BITGUARD !
So if someone has this problem, and goes here searching the solution, I think you must try any free Malware remover program to see if Bitguard should not be your problem !
Regards,
Olivier.
I also had this problem, and luckily found a solution.
First off is more of a workaround, but seemed to work. Disable parallel build in Visual Studio
(Tools -> Options ->Projects and Solutions -> Build and Run. Change maximum number of parallel builds to 1).
This resolved the issue for me, but did not solve the problem.
The issue I had, as obscure as it is, was I had Razer Synapse set up to record mouse and keyboard stats on Visual Studio. Once I disabled this, everything worked perfectly.
When our company changed anti-virus software, an application that had not been touched in months suddenly started having the build error
"csc.exe" exited with code -532462766..
I used our new AV client to scan the bin folder of the application that wouldn't build. The AV client claimed it was infected with W32.Trojan.Genkd. Uninstalling that AV software allowed it to build as usual. I think a single file got quarantined, preventing the build.
Your options may be these:
disinfect the files (assuming it's an actual infection)
unquarantine the "infected" files (assuming it's actually safe)
uninstall / disable that AV client
change AV software
Lastly, you could always comment blocks of code to identify what is causing the false-positive.
I got this error when running from the devenv command. Adding /SafeMode to the command arguments solved my issue which lead me to think one of my install extension/plugins for VS2015 was to blame.
I Resolved the same issue by Restarting my PC and that's it.

BootstrapPackage did not load correctly VS 2010

I just installed VS 2010 v 10.0.30319.1 RTMRel on 64bit Win7 Ultimate and keep receiving the following error when I try to open a web project. I have repaired and reinstall but the issue persists. I am looking for resolution suggestions. Thanks
The 'Microsoft.Data.Entity.Design.BootstrapPackage.BootstrapPackage, Microsoft.Data.Design.BootstrapPackager, Version 10.0.0.0.... did not load correctly.
This was happening to me as well. In my case I installed Visual Studio on my D drive which is not my system drive. After reading a link found in ChiliYago's blog post I found that the root cause was that files were missing from %ProgramFiles%\Microsoft Visual Studio 10.0\Common7\IDE (Which is what the error message says).
In my case, the missing files were installed in C:\ProgramFiles (x86)\Microsoft Visual Studio 10.0\Common7\IDE and not D:\ProgramFiles (x86)\Microsoft Visual Studio 10.0\Common7\IDE. My solution was to copy the missing .dlls from the install directory on the C drive to the install directory on the D drive, and the error stopped happening.
I had previously installed an Express edition of C# and un-installed it before adding Visual Studio 2010, this may have contributed to the problem for me.
In my case, I Installed Entity Framework June 2011 and then uninstalled it. After this I had this problem.
Nothing found in internet worked and when I was going to format I found in the directory: C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\CommonExtensions\ these 2 files:
Microsoft.Data.Entity.Design.BootstrapPackage.pkgdef
Microsoft.Data.Entity.Design.Package.pkgdef
Here is when VS 2010 is trying to load the library that cannot load.
I have another PC with Entity Framework 4.0, and it doesnt have these files, so I have moved them out to the desktop. Now Visual Studio is loading the project succesfully.
On the other hand, my problem also was that If I choose to hide the error message then Entity Framework 4.0 didn't create the .Designer.cs of the Model. then when I tried to add the Domain Service Class to the project, the context class didnt appear (but yes in another machine with the same project and same database).
Now that I have not the error message everything looks working good.
I hope it helps others because I have had this problem during weeks.
Best Regards,
Tried the uninstall and reinstall of Visual Studio 2010… Still that had the damn annoying message about the Missing Assembly.
Looked on the C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\ Directory which only showed:
Microsoft.Data.Entity.Design.DLL
Installed a LOT of Windows Server 2008 files (32 Bit OS) in regards to SQL Server 2008… ADO.Net, etc… STILL didn’t solve the issue! GRRRRRRR!
So I finally fixed the issue by reading between the lines. See the details below on how I resolved this issue…
This points to the MISSING Assembly:
Microsoft.Data.Entity.Design.BootstrapPackage, Version=10.0.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a
HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/VisualStudio/10.0/Packages/{7A4E8D96-5D5B-4415-9FAB-D6DCC56F47FB}
Renamed Key to:
HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/VisualStudio/10.0/Packages/{7A4E8D96-5D5B-4415-9FAB-D6DCC56F47FB}-123
Problem Solved for now in Visual Studio 2010!
Hope this helps someone else resolve this issue!
I've managed to completely remove VS 2010 from my computer using official utility and then reinstall it. Problem disapeared.
From tools menu in VS2010 select Import and Export Settings...
Select the last option, reset settings.
Save them, why not :)
Select a canned default, such as Visual C#.
Post your differences here, so that you know what to re-enable, and Microsoft people know what needs to be fixed.
I've had same problem, i solved it by rapairing it from "Control Panlel" clicking "Change/Remove" and tan choosing "Repair". BTW i'm using Win XP but i think that uninstallers in Visual Studio are the same. So.. Good luck!

Resources