Did you register the AjaxPro httpHandler in the web.config file? <httpHandlers> <add verb="POST,GET" path="ajaxpro/*.ashx" type="AjaxPro.AjaxHandlerFactory, AjaxPro"/> </httpHandlers>
This must appear in the system.web section of the configuration Joseph Guadagno http://josephguadagno.net -----Original Message----- From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of ZIV Sent: Saturday, June 17, 2006 10:21 AM To: Ajax.NET Professional Subject: [ajaxpro] Null or not an Object Am still strugling to get started with the Ajaxpro.. here is the situation, i'm trying to write a very simple code for getting the Time from the srver. here is the code: users.aspx - javascript: --------------------------------- <script type="text/javascript"> function getServerTime(){ users.usersWebForm.GetServerTime(getServerTime_callback); } function getServerTime_callback(res) { alert(res.value); } </script> users.aspx.cs: --------------------- [AjaxPro.AjaxNamespace("users")] public partial class usersWebForm : System.Web.UI.Page { [AjaxPro.AjaxMethod] public DateTime GetServerTime() { return DateTime.Now; } protected void Page_Load(object Src, EventArgs E) { // Register Ajax.NET methods from this class AjaxPro.Utility.RegisterTypeForAjax(typeof(AjaxPro.Services.AuthenticationSe rvice)); AjaxPro.Utility.RegisterTypeForAjax(typeof(usersWebForm)); if (IsPostBack) {} } } ------ i get a javascript Error: users.usersWebForm is Null or not an Object.. any advise ? Thanks, Ziv --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
