shane2004 Posted August 29, 2008 Report Share Posted August 29, 2008 Hi, I find a problem when setting RenderFormat = ".Net", the OnUserCommend Event cannot be fired. But it is working all right if switched to "Image" Quote Link to comment Share on other sites More sharing options...
shane2004 Posted August 29, 2008 Author Report Share Posted August 29, 2008 Also if the RenderFormat = "Image", the hoverover on the customised icon didn't show icon properly with red cross on top of the icon. But it is working all right if switched to ".Net" Quote Link to comment Share on other sites More sharing options...
Frank Posted September 2, 2008 Report Share Posted September 2, 2008 Two things: 1) ToolBar commands are NOT sent back to the server when using the .NET Client Control. The UserCommand event is fired in the client and can be captured using JavaScript. You can then post a call back to the server by either doing a postback or an AJAX call. Check out the following KB articles for details about capturing events in the client and sending AJAX callbacks to the server: Q6141001. Security settings required by the .NET client control URL: http://support.softwarefx.com/ShowArticleSep.aspx?Type=KB&Product=CfxNet70&Source=http://support.softwarefx.com/kb/614/1/001.htm?_r=1 Q7651001. Chart FX for VS 2005 and AJAX URL: http://support.softwarefx.com/ShowArticleSep.aspx?Type=KB&Product=CfxNet70&Source=http://support.softwarefx.com/kb/765/1/001.htm?_r=1 2) When rendering a custom command as an image, you need to provide an image file for your command and place it under: /yourapplication//UserCommands/<your command id>.png. Quote Link to comment Share on other sites More sharing options...
shane2004 Posted September 2, 2008 Author Report Share Posted September 2, 2008 Thanks, Frank. However the solution for fixing the custom command is not working. The icon is appearing when first loaded, but not when you hover over it. Can you send me an exmple? Quote Link to comment Share on other sites More sharing options...
Frank Posted September 2, 2008 Report Share Posted September 2, 2008 This works for me: Command cmd = new Command(1); cmd.Text = "My Command";cmd.Script = "MyCommand"; chart1.Commands.Add(cmd); chart1.ToolBar.Insert(0,new ToolBarItem(1)); // 1 beign your command idThen I have 1.png located under a UserCommands folder (on my application's root). Quote Link to comment Share on other sites More sharing options...
shane2004 Posted September 3, 2008 Author Report Share Posted September 3, 2008 Thanks, Frank, however I realised the issue only occurs when you build the project by using IIS web server but not the visual studio development server. Any suggestion? 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.