Visual Studio Tab Labeled Wrongly - javascript

Thank you in advance for any help you can provide me. I am trying to follow along in self guided course that didn't state the extension installs until it was too late.
What I mean by that is they just told me to install Visual Studio Code, and than went ahead with the lesson. After installing a prompt asked me while I was typing this if I wanted to install C#. I approved, and then cpl minutes later the instructor said I only needed to install live server. I also noticed their tab was labeled JS, but my tab was labeled C#.
I uninstalled C#, but still didn't get rid of it. I installed a Java Script extension still didn't get rid of it. I closed and opened multiple times. I uninstalled/reinstalled multiple times. Even restarted my computer a a couple of times. Everyone else has the JS, but I have the C#.
Working on a windows 10 I think i5 processor.
What do you think I should do?

I fixed it..... all I had to do was go to "save as" and choose java script and now its yellow like everyone else's.

Related

Visual Studio 2015 Very Slow File Opening?

I just downloaded VS15 2015 Community on my Windows 10 machine, and just installed all of the default packages.
For whatever reason, if I try to open a javascript file, or nearly any other extension, it takes about a full 15-20 seconds for it to load. This code says nothing but the word test in text.
Now for whatever reason, if I decide to right click the javascript file and select
Open With > "Microsoft Visual Studio Version Selector"
instead of with plain Microsoft Visual Studio 2015, it opens instantly, in like 2-3 seconds tops...
What is going on? This is so irritating! I've already reinstalled VS 3 times, cleaning out all old junk files, and even tried running it without a single tool or extension installed, and it still behaves this way unless I open it with Visual Studio Version Selector, which happens to not be listed in my list of default programs in the control panel, just the original Microsoft VS 15, so I can't even set it to that as a workaround.
If anyone know what could be wrong or a possible fix, please let me know!
Thank You!
I appreciate this is an old post but I had the same problem and was looking everywhere for a solution.
What worked for me and the rest of my team was to delete the contents of the '_references.js' file that's in the 'Scripts' folder in the project. It has something to do with intellisense which doesn't seem to work anyway which makes the file completely useless. Our project is very large with a lot of js files so I don't know if that was the problem but when it was refreshing the intellisense it took ages and this seems to stop that happening.
Hope this helps someone! :)
Reference: http://madskristensen.net/post/the-story-behind-_referencesjs

Eclipse hangs when editing javascript

I added Angular-eclipse plugin in my eclipse. now when i am trying to edit any of my javascript file my eclipse hangs.
for example whenever i put "." and wait for js suggestion my eclipse hangs with not responding.
could any one assist on this.
I once had an issue in Eclipse, but with another JS framework which is Sencha EXTJS. Some people say Eclipse does not get along very well with JS, at that point when I was learning JS, I'd have liked to use IntelliJ but, you know, we want to save our bucks for the future :). In addition, I remember I installed the Sencha EXTJS plugin but same issue, my Eclipse hanged and I had to try to make my changes in a notepad, neh, just kidding, but yes, I faced a similar problem like you.
By that time I used to edit my JS using SublimeText, VIM or Aptana (you could also try them).
But, since you seem to like Eclipse (as much as I can, I love that IDE)... you can make something similar to what I did some time ago, follow the steps of the following guide:
http://flexblog.faratasystems.com/2013/04/24/configuring-eclipse-with-apache-tomcat-and-ext-js
Does not matter what your server is (neither your framework), I think this configuration steps can be the "basics" for what you need.
Hope it could help you or at least give you some clue on how to have the environment in which you can feel comfortable to make some code :).
Regards and happy coding :)
This may help
In your eclipse,
1) Go to Help
2) Click Eclipse marketplace
3) search - optimizer
install "optimizer for eclipse"

Visual Studio 2010-intellisense and highlighting in javascript doesn't work

In one of my solutions in javascripts files the intellisense suddenly stopped working.
All of the features are disabled - ctrl+space doesn't bring the list - like this
I took the print screen from another solution
and also the file looks like it was plain text -keywords has no colors.
I tried to open new solution and move the files there - still the same.
Files has intellisense only when I am debugging.
It feels like VS2010 see that those files are text files instead of js files.
It has something to do with tfs because it first happened to another member of the team and as soon as I took latest version of the solution - it happened to me.
When I create new js file - it looks fine , BUT after saving
the file , closing and reopen - again it is not colored
I found out that the problem is in one specific project - if I add js files to another project in the same solution it seems to be ok.
After some research and tests. This problem could be a couple of things:
Your file's extension is not .JS.
You are using an express edition.
You have not installed the Web Developer component on your installation (or removed it).
Let me know if this help you, If not I will look forward something else.
The complete reference about the JScript Intellisense on msdn:
http://msdn.microsoft.com/en-us/library/vstudio/bb385682(v=vs.100).aspx
As you can see in the image below, I just created a single javascript file in my Visual Studio 2010 with Web developers components and it is working:
So I solved this problem ....
I wanted to watch some value with QuickWatch (Shift+F9)
I got the message "Unable to evaluate the expression. The object invoked has disconnected from its clients." I pressed the green icon to refresh the values. After I closed the QuickWatch window I realized that I got the intellisense and highlighting back.
After a checkin to TFS, my colleague pulled the solution and got the intellisense and highlighting back as well.
Probably some weird bug in VS2010.

Viewing the updated HTML in ie6

I am working with ie6 (unfortunately) and i am having a javascript error. Its wondrous error message gives me a line in the html source, but unfortunately the javascript that does run changes the code for the page(dramatically). So the error that its pointing me to is a closing div tag, not actual code.
Is there a way to view the updated code for the page so I can at least know where my code is breaking?
I should also point out what im developing in.
I am developing a sharepoint 2007 solution for an winxp and ie6 user base. I am working via remote desktop on a sandbox winserver 2008 r2 and can access the site from my terminal. Now, unfortunately in my sandbox server i have ie 8 in which my code works. So im stuck on ideas. If anyone knows how to view the updated source on the page, i would be very grateful.
Thanks.
Edit. I should also mention i dont have admin access on my terminal. So i cant install visual studio. It would take a couple weeks for an issue ticket for temp admin access to install it, and this is sort of important.
If you can't install anything and the error console information isn't meaningful, then about all you can do is start modifying your code until you can find which section is causing the error. The kinds of modifications you can do are as follows:
Comment out a chunk of code in a way that won't cause more errors. If the error goes away, then you know it's in that block of code or something that code calls. Put that block back in and then comment out a piece of it and so on until you narrow down where the problem is.
Start inserting alert("1"), alert("2") prompts into your code with the goal of identifying which alert the error comes before and after until you've eventually tracked down where it is. When you rule out an area, remove the alerts to make it feasible to still run the app.
On a more modern computer (e.g. Vista/Win7) go to Microsoft's site and download both Microsoft Virtual PC and the Windows image for XP with IE6. You can then actually install things into the VM and do real IE6 debugging or at least see what the actual error is.
Find a computer with XP/IE6 on it that you can install real debugging tools on.
Build your own dummy little debug window using a textarea and a couple functions that append text to it. Put that into your browser page and start sprinkling mydebug("Entering function foo") statements throughout your code so you can narrow down which statements occur before and after the error and eventually find the error. This is how I've done some IE6 debugging when it was't worth the trouble of setting up a full-blown debug environment for IE6. This works much better than alerts for some types of problems because it doesn't interrupt the flow of the app or require lots of user intervention and you can scroll back through the history.
If you are using visual studio you can use it to debug js errors in ie.
Go to the Advanced Internet settings in ie and make sure that the two
Disable script debugging settings are turned off (so that script debugging is enabled)
and that the setting
display a notification on every script error is enabled.
If you don't have visual studio installed you can download and install microsofts script debugger (it's free just google it) and use that, tho it is not as easy to work with and won't give you as much useful information

How to stop IE asking which debugger to choose when **trying** to debug?

When debugging in Internet Explorer, I first get an alert box with extremely limited if not useless information (sorry IE) and choose to debug it. After selecting yes, I get another option every time to choose between 'New instance of Microsoft script debugger' and 'New instance of Visual Studio'. I'm fed up with having to click the yes button again after having clicked it once already on the alert box.
Update: I found that you can disable the Microsoft script debugger from within its own options; just disabling the JIT debugger from Tools -> Options, and JIT. This stops it appearing on the menu but now I get the dialog box asking me which one to choose and it only displays the Visual Studio - WHY? If there's only one option and you've already asked me if I want to debug, why ask again?!?! Bleh.
Can you tell I'm getting sick of clicking, "yes" twice? Lol.
Apparently the problem happens if you do not uninstall the old (crappy) Microsoft Script Debugger before you install the newer Microsoft Script Editor.
You would think that all you need to do is to uninstall the old debugger - however, according to a blog posting (which I can't recall at the moment), if you uninstall the Microsoft Script Debugger at this point, it will mess up the MSE and you will have to reinstall the MSE again. I am on a tight schedule now so I don't have the time to fix the problem properly - just living with it as best as I can.
Maybe not the complete solution, but you could try to set the default script debugger can be set in the registry directly. To do so, follow these steps:
Click Start, Run and type regedit.exe
Navigate to the following branch:
HKEY_CLASSES_ROOT \ CLSID \ {834128A2-51F4-11D0-8F20-00805F2CD064} \ LocalServer32
Backup the branch by exporting it to a file
In the above key, double-click (default) and set its value data to:
"C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\devenv.exe"
(or whatever your path to devenv.exe is)
Exit the Registry Editor.
If all other solutions fail, you can try another route: using a macro language (à la AutoHotkey or AutoIt) to dismiss all prompts with one key...
This is not what you're asking for, but others coming to this thread may want to know how to disable these completely. Just disable debugging all together under:
Options -> Advanced -> Browsing -> Disable script debugging.
Just disable the Machine Debug Manager in the list of the Services!
This happens because that's how the just in time debugging thingy was designed.
Generally I have multiple instances of Visual Studio running and that little box lists them all so I can pick the right one. You would think it would be smart enough to just pick the one option if there is only one option, but it isn't.

Categories