Jump to content
Software FX Community

How to interact on client side?


User (Legacy)
 Share

Recommended Posts

Hello,

I am trying to set a Series to visible=FALSE when the user choses a command

from the context menu (right-click). I get an event when this happens, but

how do I get hold of the Chart and Series...? Is this even possible...?

It would have been nice if it could have worked something like the code

below, but how do I do this for "real"?.

Sub Chart1_UserCommand(wParam,lParam,nRes)

if wParam = 20 then

Chart1.Series(1).Visible = FALSE

end if

end if End Sub

Regards,

Rolle

NB. I'm using ChartFx 5.5.

Link to comment
Share on other sites

Thanks for Your answers FP! But I think You have missunderstood what I'm

trying to do (?)...well, I probably haven't explained it too well either. :)

I have no need to know exactly where or what the user clicks. All I want is

a command in the righ-click menu (which is no problem, works fine). I want

to capture this even on the clients side (again, no problem). The thing I

want to do next is to make a graph "invisible" (one of the series in the

graph actually) by getting hold of the actual Chart object on the client

side. I don't want server interaction just to make a series in the chart

invisible.

Longer description:

The chart is drawn with a couple of different series. Year-to-date is one of

these (series 1). Default for this serie is that it's invisible, ie. only

the original data is shown (series 0). Now the user can right-click the

chart, and chose to show the YTD series too. Series 1 gets visible. And I

want to do this on the client side, no re-loading of the page. Is this

possible? That is, getting a hold of the actual chart object on the client

side and making a series visible/invisible. Or do I have to do those kind of

things on the server side?

Shorter question:

How do I get the Chart object on the client side so I can perform actions

(get/set) to it?

Hope You understand what I'm trying to do..?

Regards,

Rolle

"SoftwareFX Support" <support@softwarefx.com> skrev i meddelandet

news:xHIaS1oADHA.3076@webserver1.softwarefx.com...

> You can capture the RButtonDown event and determine the Series and Point

> that was clicked. Then when you get the user command event you will know

> which series/point it corresponds to.

>

> --

> FP

> Software FX, Inc.

>

>

Link to comment
Share on other sites

The script you wrote:

Sub Chart1_UserCommand(wParam,lParam,nRes)

if wParam = 20 then

Chart1.Series(1).Visible = FALSE

end if

end if End Sub

Is fine, the "Chart1" name is the default but it can be changed when you

call GetHtmlTag, you define the name you want as follows:

<%= Chart1.GetHtmlTag(100,100,"ActiveX","Chart1) %>

<%= Chart2.GetHtmlTag(100,100,"ActiveX","Chart2) %>

This way you can control the names of the client objects.

--

FP

Software FX, Inc.

Link to comment
Share on other sites

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...