Sep 21, 2011, 6:57 AM
[CLOSED] DirectMethod with UserControl Problem
Here is the sample of the code (where the function "directmethodFunction" is being called from a Listener).
I tried to check the example as well as some existing issues related to DirectMethod but so far I get
"object doesn't support this property or method" error.
Parent.aspx
I tried to check the example as well as some existing issues related to DirectMethod but so far I get
"object doesn't support this property or method" error.
Parent.aspx
<%@ Control Language="C#" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<script runat="server">
ucUserControl= (UserControl)this.LoadControl("UserControl.ascx");
ucUserControl.ID = "UserControlID";
this.panel1.ContentControls.Add(ucUserControl);
</script>
UserControl.ascx<%@ Control Language="C#" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<script runat="server">
[DirectMethod]
public static void LogException(string e)
{
X.Msg.Alert("LogException", e).Show();
}
</script>
<script type="text/javascript">
var directmethodFunction = function(){
Ext.net.DirectMethods.LogException('testing');
}
</script>
Last edited by Daniil; Sep 21, 2011 at 8:41 AM.
Reason: [CLOSED]