Hi,
I'm currently working on introducing AJAX to an existing C#.NET web app
and have run into some difficulties. Essentially, for the onChange
event for a select box, I'm going back to the server to get a string
(for now, basic test). My calls to the server side are working
properly, however the value on my textbox is not getting updated on the
client.
I think the problem is occuring because the request is being sent from
a .aspx page, but the textbox/inputbox I'm looking to change the value
on is on a .ascx control. This control is used numerous times on the
aspx page. Below is the function that is calling the server with the
appropriate value and callback function. These both work.
app.test.strAssetFiltered(oStartingContainer.value,
getAssetType_callback);
This is the function on the server side and if I step through it, it
works!
[AjaxPro.AjaxMethod]
public string strAssetFiltered(int makeValue)
{
if (makeValue == 08)
{
return "Car";
}
else if (makeValue == 11)
{
return "SUV";
}
return "Truck";
}
The below callback funtion works, however, the value is not upated on
the UI. If I save the page and reload it, the value that I would
expect to see immediatly after this function is executed is there.
function getAssetType_callback(res)
{
document.getElementByID("Purchased_assets1__0_Asset_description1_strFeatures").value
= res.value;
}
Any ideas? This is a .net1.1 app using the
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ajax.NET Professional" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/ajaxpro
The latest downloads of Ajax.NET Professional can be found at
http://www.ajaxpro.info/
Don't forget to read my blog at http://weblogs.asp.net/mschwarz/
-~----------~----~----~----~------~----~------~--~---