HtmlChart inside RadDock

6 posts, 0 answers
  1. Mohamed
    Mohamed avatar
    4 posts
    Member since:
    Apr 2013

    Posted 23 Apr 2013 Link to this post

    Hello Team,
    I am using a Rad Html Chart to display contents from Database, also i have placed the chart inside a Rad Dock. The chart which i use is a Drill Down Chart. It gets loaded well and good for the first time. But when i make a click on the client series item the drill down chart disappears. 
    Also i use Rad Ajax Manager in Master Page and Chart is in client page. Can you please offer me a solution.
  2. Danail Vasilev
    Admin
    Danail Vasilev avatar
    1492 posts

    Posted 25 Apr 2013 Link to this post

    Hello Mohamed,

    It is possible that you are not properly accessing the HtmlChart inside the RadDock. You should initially get a reference to the RadDock inside the content place holder, and then access the HtmlChart through the content container of the RadDock. For example:
    RadDock myRadDock = (RadDock)ContentPlaceHolder1.FindControl("RadDock1");
    RadHtmlChart myRadHtmlChart = (RadHtmlChart)myRadDock.ContentContainer.FindControl("RadHtmlChart1");

    However, I am not sure what is the real cause for your issue, as I do not have enough information about your actual scenario. Therefore I have created a VS example, attached to this post, that demonstrates how to create a drill-down chart, inside a RadDock. The example is a modified version of HtmlChart - Drill-down Chart online demo.

    Regards,
    Danail Vasilev
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Mohamed
    Mohamed avatar
    4 posts
    Member since:
    Apr 2013

    Posted 28 Apr 2013 Link to this post

    Hello Mr.Danail,
                             Thanks for your fast reply. Your reply was much useful. Now i have another issue, and i need your help. I have a RadHtmlChart inside a RadDock and on drill down in need to refresh only Rad Dock not the whole page, also i want to know is that possible to do so without using AjaxManager.
  5. Danail Vasilev
    Admin
    Danail Vasilev avatar
    1492 posts

    Posted 30 Apr 2013 Link to this post

    Hi Mohamed,

    The main idea of the RadAjaxManager is to make partial page updates and not to postback the whole page. That is what exactly the provided example does - it updates only the RadHtmlChart that is inside the RadDock and not the whole page. You can get more acquainted to the RadAjaxManager by going through the sections in our online help as well as the online demos.

    Regarding the ajaxifying of the content of RadDock without RadAjaxManager, note that this is a general knowledge related to AJAX and not to RadControls. Nevertheless you can find how to do that in the attached example which is a modified version of the last example I have sent. Said shorty:
    • The content of the RadDock is wrapped inside an update panel, in order to ajaxify that part of the page.
    • A Radbutton has been put on the master page that will in replicate the job of the RadAjaxManager's OnAjaxRequest handler by triggering the server-side OnClick event and getting the CommandName argument of the Button
    • In the client-side OnClientSeriesClicked event, the category of the HtmlChart is passed as a commandName to the postbackButton. Then the client-side click of the button itself is triggered, in order to simulate the ajax request.
    • The postbackButton is hidden as its purpose is to perform only a postback and not to be visible. The client-side set_visible() method is used, so that the button's object is available.



    Kind regards,
    Danail Vasilev
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  6. Mohamed
    Mohamed avatar
    4 posts
    Member since:
    Apr 2013

    Posted 02 May 2013 Link to this post

    Hello Mr.Danail,
    Thanks for your detailed timely reply. But the worst part is that i have not reached the solution which i need. And kindly i need to inform you that the first example given buy you has a defect. The chart gets loaded for the first time but when i do drill down, the chart gets disappeared. In short, drill down is not working in your first example, and in the second the drill down works good, but the entire page is reloaded when doing so. 
    I kindly request you to provide me an exact solution for my issue, in short make your first example to work good and resend me sir. Thanks
  7. Danail Vasilev
    Admin
    Danail Vasilev avatar
    1492 posts

    Posted 07 May 2013 Link to this post

    Hello Mohamed,

    Regarding the RadHtmlChart-DrillDown-RadDock.zip demo I have tried to reproduce the described behavior but to no avail. You can watch a short video with the test here, and then tell what I am missing.

    I have used the Telerik.mdf database and the corresponding fields like in the HtmlChart - Drill-down Chart online demo.  It might be possible that you are referencing invalid fields from this or other database. However, without having enough information about your actual scenario it is difficult to reproduce the unexpected behavior. What I can suggest you is to open a support ticket and send us a fully runnable sample with reproduction steps of the issue, so we can proceed further with the investigation.

    Regarding the second example - RadHtmlChart-DrillDown-RadDock-UpdatePanel.zip, you are right that the drill down clicking performs a full postback and not partial one, so please accept my apologies for the caused mistake. The reason for the unexpected behavior is because the hidden button that is being clicking is put outside of the update panel's boundaries. What I have done in order to fix that was to move the button itself together with its server-side event inside the area of the update panel. Please find the reworked example in the attached archive.


    Kind regards,
    Danail Vasilev
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017