Go Back   Velocity Reviews > Newsgroups > ASP Net
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

ASP Net - ASP.NET 2 ICallbackEventHandler

 
Thread Tools Search this Thread
Old 11-01-2005, 02:02 PM   #1
Default ASP.NET 2 ICallbackEventHandler


Hello everyone,

I have upgraded to ASP.NET 2 and since then i had the code below stopped
working after upgrading and modiftying the code:

using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;


public partial class test2 : System.Web.UI.Page, ICallbackEventHandler
{
protected void Page_Load(object sender, EventArgs e)
{
String cbReference =
Page.ClientScript.GetCallbackEventReference(this," arg", "ReceiveServerData",
"context");

}

public String GetCallbackResult()
{
return "any thing";
}



public String RaiseCallbackEvent(String eventArgument)
{
String returnValue;

if (catalog[eventArgument] == null)
{
returnValue = "-1";
}
else
{
returnValue = catalog[eventArgument].ToString();
}

return returnValue;
}

}

I always get the following message:

Error 1 'test2' does not implement interface member
'System.Web.UI.ICallbackEventHandler.RaiseCallback Event(string)'.
'test2.RaiseCallbackEvent(string)' is either static, not public, or has the
wrong return type. c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temp orary
ASP.NET Files\clientfeatures\24208b06\718d08ed\App_Web_e2q wrp_y.0.cs 14

I would be grateful if anyone has a solution for this.

Thanks a lot,

Maya.




Maya Nasri
  Reply With Quote
Old 11-01-2005, 07:02 PM   #2
=?Utf-8?B?RXJpYyBXaXNl?=
 
Posts: n/a
Default RE: ASP.NET 2 ICallbackEventHandler
I believe that raisecallbackevent needs to be of type void

"Maya Nasri" wrote:

> Hello everyone,
>
> I have upgraded to ASP.NET 2 and since then i had the code below stopped
> working after upgrading and modiftying the code:
>
> using System;
> using System.Data;
> using System.Configuration;
> using System.Collections;
> using System.Web;
> using System.Web.Security;
> using System.Web.UI;
> using System.Web.UI.WebControls;
> using System.Web.UI.WebControls.WebParts;
> using System.Web.UI.HtmlControls;
>
>
> public partial class test2 : System.Web.UI.Page, ICallbackEventHandler
> {
> protected void Page_Load(object sender, EventArgs e)
> {
> String cbReference =
> Page.ClientScript.GetCallbackEventReference(this," arg", "ReceiveServerData",
> "context");
>
> }
>
> public String GetCallbackResult()
> {
> return "any thing";
> }
>
>
>
> public String RaiseCallbackEvent(String eventArgument)
> {
> String returnValue;
>
> if (catalog[eventArgument] == null)
> {
> returnValue = "-1";
> }
> else
> {
> returnValue = catalog[eventArgument].ToString();
> }
>
> return returnValue;
> }
>
> }
>
> I always get the following message:
>
> Error 1 'test2' does not implement interface member
> 'System.Web.UI.ICallbackEventHandler.RaiseCallback Event(string)'.
> 'test2.RaiseCallbackEvent(string)' is either static, not public, or has the
> wrong return type. c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temp orary
> ASP.NET Files\clientfeatures\24208b06\718d08ed\App_Web_e2q wrp_y.0.cs 14
>
> I would be grateful if anyone has a solution for this.
>
> Thanks a lot,
>
> Maya.
>
>
>



=?Utf-8?B?RXJpYyBXaXNl?=
  Reply With Quote
Old 11-02-2005, 10:34 AM   #3
Maya
 
Posts: n/a
Default Re: ASP.NET 2 ICallbackEventHandler
You are a star!

never thought that i would need to modify a code retrieved from
microsoft msdn site!

thanks a alot.

Maya.



Maya
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
viewstate MAC failed in asp.net 2.0 while postback the page azraffarveen Software 0 05-12-2009 03:24 PM
.NET 2.0 Web Apps / .NET 3.5 ASP.NET Apps - Differences/Similariti london1919 MCTS 1 12-08-2008 03:16 PM
ASP.NET: Asign Users in Roles(Array.IndexOf(Of String) method) msandlana Software 0 04-25-2008 06:37 AM
ASP.NET deadlock viktoria Software 0 07-05-2007 02:53 AM
ASP.NET 2.0 application does not run in WIN2k3 johnfraj Software 0 04-19-2007 08:27 AM




SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46