JScript IntelliSense March CTP Gotchas + Workarounds

Web Development Tools Microsoft

The March CTP is of course a “Preview” and does have some bugs.  I thought we’d share the top issues seen and offer some workarounds.

1. TypeLibBuilder.exe “has encountered a problem…”

If you’re seeing this:

This a bug where that particular assembly has not been given a Strong Name.  The solution is to turn verification off for this one assembly.  To do so, place the following text in a text file, rename the extension from “txt” to “reg”, then run (double-click) the file.

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\StrongName\Verification\TypeLibBuilder,b03f5f7f11d50a3a]

Alternatively, you could manually input this if you’re handy with the Registry Editor.  If you’re familar with SN.exe, the -Vr option should do the same.  Note: for security reasons, we don’t normally recommend disabling Strong Name verification unless you know what you’re doing. =)

2. Functions and Objects declared in external files aren’t showing up

In the CTP, IntelliSense for the active document is not aware of changes made in other documents (external scripts).  Thus, if you add a function in document B, you won’t see it show up in document A.  The workaround is to close and reopen the document.  This forces the editor to look for any changes.  Note: this issue is fixed internally, but it might be a while before it is publicly available.

3. Functions and Objects declared in external files aren’t showing up (still!)

Errors in an external script can cause certain members not to show up in IntelliSense.  If this is the case, we’ll give you the error and the line number in the status bar:

For reasons outside the scope of this post, the external script is actually executed in a sandboxed script engine.  There are actually a few instances where script may fail due to the fact that it’s not in an actual browser.  I would love to hear about any of these cases so we can better adjust our design.

4. XML Doc Comments not showing up

Per our current design, we are only able to process XML Doc Comments in external files (that you’re referencing from the current file).  In short, external files are processed in a separate engine than the current file.  That engine understands XML Doc Comments.  The engine running the current document does not.  There were limited resources and the rationalization was that external files (often written by someone else) are where comments count the most.  Let us know if you don’t agree with this. =)

5. Common XML Doc Comment misspellings

I often find myself not mindful of the spelling of two tags.  It might be worthwhile to reiterate that <reference /> lacks an “s” and <returns /> has one.

I hope this information makes your “previewing” experience a better one!

Jeff King
Program Manager
Visual Studio Web Tools

0 comments

Discussion is closed.

Feedback usabilla icon