Mohamed Posted October 23, 2007 Report Share Posted October 23, 2007 Hi all, Using chartfx 6.2 for .net with Vs 2005 I am designing an interactive bar chart. while clicking on the interactive chart ,I want to open up new Asp window(belongs to other reporting application) by posting values from my form to Asp form.So please let me know how to openup new window by posting values(javascript) and also how to set the tooltip for each bar with the xaxis labels. I would appreciate your help on this. Thanks Mohamed Quote Link to comment Share on other sites More sharing options...
Frank Posted October 24, 2007 Report Share Posted October 24, 2007 You need to set the Url property for the chart to a javascript function. For example: chart.Link.Url = "javascript:MyFunction(%S,'%l')"; In this example, the function is receiving 2 parameters: the series index and the X-Axis label (assuming you have one). You can use any "%" macro available in TipMask and PointLabelMask. Your JavaScript will look something like this: <script language="javascript" type="text/javascript"><!--function MyFunction(seriesIndex, xAxisLabel) { alert(seriesIndex.toString() + xAxisLabel); }// --></script> Quote Link to comment Share on other sites More sharing options...
Mohamed Posted October 24, 2007 Author Report Share Posted October 24, 2007 Chrt_LREvsWPA.Link.Url = "BLOCKED SCRIPTMyFunction('%l')" JavaScript: <script language="javascript" type="text/javascript"> function MyFunction(d) { alert(d); } </script> I tried as you told. My chart page URL is http://localhost/EIA(LRE)Website/LRE/LREvsWPA.aspx (FYI - attached the chart page) When I click on one of the interactive bar of the chart. Logically it should give javascript alert, Instead it redirects or takes you to:(unavailable page) http://localhost/EIA(LRE)Website/LRE/BLOCKED%20SCRIPTMyFunction('D1') you can clearly see in above url that (pls Compare and see above two URLS) Chrt_LREvsWPA.Link.Url = "BLOCKED SCRIPTMyFunction('%l')" This "BLOCKED SCRIPTMyFunction('%l')" is called as a Page by Chrt_LREvsWPA.Link.Url property . Please let me know where I am going wrong. Thanks Mohamed Quote Link to comment Share on other sites More sharing options...
Frank Posted October 24, 2007 Report Share Posted October 24, 2007 "BLOCKED SCRIPT" is an artifact of Community Server. The Url must start with javascript followed by : Quote Link to comment Share on other sites More sharing options...
Mohamed Posted October 24, 2007 Author Report Share Posted October 24, 2007 Thank you very much for your Kind and Quick support. Mohamed Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.