GoPalette events problem with SqlServer sessions

Hello,

We are using GoDiagram(TM) for ASP.NET Web Forms version 2.6.2
We have come accross the following situation...
If we use Inproc sessions the GoPallete events seems tio work perfectly.
( web.config --> )<?:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />
But when we switched to Sqlserver sessions the eventd do not get fired.
( web.config --> )
our initialize components looks as follows:
private void InitializeComponent()
{
this.MyPalette.ObjectDoubleClicked += new Northwoods.GoWeb.GoObjectEventHandler(this.MyPalette_ObjectDoubleClicked);
this.MyPalette.BackgroundDoubleClicked += new Northwoods.GoWeb.GoObjectEventHandler(this.MyPalette_BackgroundDoubleClicked);
this.MyView.LinkCreated += new Northwoods.GoWeb.GoSelectionEventHandler(this.MyView_LinkCreated);
}
I only tested ObjectDoubleClicked and BackgroundDoubleClicked and neither of them are working under SQLServer sessions.
===================================================
Note:
The events of other web controls such as textboxes, buttons etc. work correctly and so are sessions.
Thus I am quite sure that the SQLServer session is working correctly but Gopalette is not identifying SQLServer sessions
===================================================
Does anyone have any clue to this issue.
Thanks,
-Sajjitha

So the objects in the palette are being serialized OK?

I’m guessing that the problem is that the event handlers you have defined are not being serialized. (Event handlers are usually not serializable.)

One way around this is to subclass/inherit from GoView and override the corresponding On… methods.

There’s a discussion of this in GoWebIntro.doc.

Hello,

I implemented a class which derived from GoPalette. Then I did override the On... methods that I require.
The code is as follows:
================
using System;
.....
using Northwoods.GoWeb;
namespace TestingGoWebEvents
{
[Serializable]
public class CustomGoWeb : GoPalette
{
protected override void OnObjectDoubleClicked(GoObjectEventArgs evt)
{
base.OnObjectDoubleClicked(evt);
}
protected override void OnBackgroundDoubleClicked(GoInputEventArgs evt)
{
base.OnBackgroundDoubleClicked(evt);
}
}
}
My aspx page is as follows:
===================
<%@ Register Assembly="TestingGoWebEvents" Namespace="TestingGoWebEvents" TagPrefix="CustomGoWeb" %>
....
<CustomGoWeb:CustomGoWeb id="MyPalette" tabIndex="1" BorderColor="Gray" Width="180px"
Height="400px" runat="Server" NoPost="true"
ScriptFile="GoWeb.js" ImagePage="GoWebImage.axd" CssFile="none"/>
===================================================
With this approach , when I am using the Inproc sessions still it works fine.
But when I switch to SqlServer sessions the whole GoPalette screen is blinking and the GoPalette is displaying a message indicating that it cannot find the GoWebImage.axd.
Could you look at the above code and see wether I have missed something, or wether there is some possible error in the code.
Thanks,
-Sajjitha.

Did you check to make sure your document and all of its objects are serializable? There are a number of topics in this forum about how to test that.

In version 3.0 we’ve added a GoDocument.TestSerialization() method so that you can check any document at any time for your debugging convenience.