Last post Jul 28, 2010 08:50 PM by CruzerB
Jul 23, 2010 01:14 PM|jjv88|LINK
I haven't had satisfactory results searching online for this: how to reference Microsoft AJAX (MicrosoftAjax.debug.js etc.) within a custom server serv control project in a standalone .js file. I know the "/// <reference ... />" directive but haven't figured
out exactly the name, assembly etc. attributes to put in there. I have reference System.Web.Extensions in the project and tried "/// <reference name="microsoftajax.debug.js" assembly="System.Web.Extensions />" What am I missing? Online resources for what I'm
working on are actually quite limited. I'm using Microsoft AJAX Framework to add a seamless client-side api to a custom server control. This is much akin to how telerik implements their client-side api's. On the aspx page using the control I need a script
block to be able do something like:
var valid = true;
// ... ... ...
if(valid !== true)
Microsoft AJAX Framework
Jul 27, 2010 02:31 AM|CruzerB|LINK
how to reference Microsoft AJAX (MicrosoftAjax.debug.js etc.) within a custom server serv control project in a standalone .js file.
You can copy out the .js file and embedded it into your application. It will make your life easier. Simply save a web page with "Microsoft AJAX" to your local disc, and you are able to get the file easly.
I dun think you are able to do it with the current version of Visual Studio. ^^
Jul 27, 2010 10:52 PM|jjv88|LINK
Its actually easier than I thought, it's '/// <reference name="MicrosoftAjax.js" />' (or at least one way to get some of the intellisense). I know well how to get my js embedded in the custom control's assembly, its all about getting my intellisense, or
however much is possible. MicrosoftAjax.js is available as soon as you have a ScriptManager on page, it shouldn't be included as an embedded resource with a custom control unless you are dependent on a specific (probably old) version, and even then I don't
know how and how well you get around the fact that the ScriptManager is going to bring in whichever one is in System.Web.Extensions.dll. Ah well, problem has been solved, bleeding edge client-side api is implmented. I guess that is what happens when you sit
in a chair for a 10 hours a day and just go at it.
Jul 28, 2010 08:50 PM|CruzerB|LINK
'/// <reference name="MicrosoftAjax.js" />' (or at least one way to get some of the intellisense)
wow. New thing for me.