A New Internet Library: Add Your Website/Blog or Suggest A Website/Blog to our Free Web Directory http://anil.myfunda.net.

Its very simple, free and SEO Friendly.
Submit Now....

Wednesday, December 17, 2008

Tip #35: Did you know.How to add Intellisense from script libraries for JS files?

Here is an example to add intellisense for JS files in VS 2008.

So, you have two Javascript files

Jscript1.js with the following code

function validateForm() {
}

and Jscript2.js (wherein you want current JScript file to show intellisense including objects & functions declared in Jscript1.js)

Now to add intellisense, from the solution explorer drag drop Jscript1.js into Jscript2.js.

You will notice that the following Jscript document comment has been added to the Jscript2.js file.

/// <reference path="JScript1.js" />

And now you can start using the intellisense, try typing in validateForm in Jscript2.js.

image

Thanks,
Deepak Verma
SDET | Visual Web Developer

Source Click Here.

No comments:

Post a Comment

Post your comments here:

Originals Enjoy