Jump to content
Software FX Community

User Callback and .NET Rendering


Gabriel
 Share

Recommended Posts

I have written code that generates a user callback event from javascript when an html button is pressed.  The desired effect does occur (for example, if the button should cause a line to become invisible, it does) but any changes made using the toolbar buttons are undone.  As an example, say the 3D toolbar button is pressed, the lines become 3D, not a problem.  Once the user callback is performed, the effects of the user callback are reflected in the graph but the lines become 2D again.  In particular, this occurs when .NET rendering is used.  Is this expected behaviour?

Link to comment
Share on other sites

This one was tricky!

The problem is that the changes made in the client are not seen by the ASP.NET callback framework. In order to fix this problem, you need to do either of these:

1) Set Chart.UseCallBackForEvents to true. The client component will see this and automatically refresh the Callback Data when a change is made.

2) Call SFX_RefreshCallbackData before calling SFX_SendUserCallback

Link to comment
Share on other sites

 Yes, this one is tricky indeed. lol.  I tried both suggestions and neither worked.  Following the example in the first post the lines became 2D again even though UseCallBackForEvents is set to true or/and  SFX_RefreshCallbackData() is called before SFX_SendUserCallback.  Am I maybe missing something? Or do you have any other suggestions?

I have installed the latest service pack for chartfx7.  

Gabriel 

Link to comment
Share on other sites

The only other think I can think of is Trust. The .NET Control needs full trust in order to interact with the DOM (required to store the state).

Make sure the .NET security settings are set to full-trust for this control/zone.

Both of the solutions work on my end.

Link to comment
Share on other sites

  • 3 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...