This project has moved and is read-only. For the latest updates, please go here.

Error when using MicrosoftAjax

Jul 10, 2007 at 5:09 PM
When I build, and run the application against the MicrosoftAjax project that comes in the Projects folder I get the following error:

Line: 899
Error: Sys.ArgumentUndefinedException: Value cannot be undefined.
Parameter name: instance

When I click no to debugging, the form shows the first box empty, but the second one has content that starts with:

<?xml version="1.0" encoding="utf-8"?>

<reflection xmlns:js=""

<api id="N:J:">
<apidata group="namespace" name="Global namespace"/>
<element api="T:J:Type"/>
<element api="T:J:Array"/>
<element api="T:J:Boolean"/>
<element api="T:J:Date"/>
<element api="T:J:Error"/>
<element api="T:J:Function"/>
<element api="T:J:Number"/>
<element api="T:J:Object"/>
<element api="T:J:RegExp"/>
<element api="T:J:String"/>
<element api="N:J:Sys"/>
<api id="M:J:Sys.WebForms.PageRequestManager.dispose">
<apidata group="member" subgroup="method" name="dispose"/>
<memberdata visibility="public"/>
<library assembly="" module="MicrosoftAjax"/>
<namespace api="N:J:Sys.WebForms"/>
<type api="T:J:Sys.WebForms.PageRequestManager"/>
<api id="M:J:Sys.WebForms.PageRequestManager.getInstance">
<apidata group="member" subgroup="method" name="getInstance"/>
<memberdata visibility="public" static="true"/>
<returns><type api="T:J:Sys.WebForms.PageRequestManager"/></returns>
<library assembly="" module="MicrosoftAjax"/>
<namespace api="N:J:Sys.WebForms"/>
<type api="T:J:Sys.WebForms.PageRequestManager"/>

Any idea on what is causing the JavaScript error?
Jul 17, 2007 at 7:59 PM
What version of Ajax is installed on this machine?
Jul 17, 2007 at 9:06 PM
I have version 1.0.61025 installed.
Sep 15, 2007 at 9:49 PM
I have the same version and I'm seeing the same problem. What has to be done to fix it? I'm using the sample project in the download.

Sep 15, 2007 at 10:09 PM
Edited Sep 15, 2007 at 10:10 PM
It appears the given example using the "name" attribute doesn't work with the newer version of Ajax. I tried adding the "assembly" attribute but that didn't make a difference. Using a path to regular script file does work though.

Sep 18, 2007 at 1:01 AM
Edited Sep 18, 2007 at 1:04 AM
I'll upload a new release in a minute, but this is easily fixed by removing the RoleService singleton in the project file.