Customize OrgChart example with SharePointList

5 posts, 1 answers
  1. Helga
    Helga avatar
    3 posts
    Member since:
    Jan 2013

    Posted 15 Jan 2014 Link to this post

    Hello,

    i want to customize the OrgChart Example http://demos.telerik.com/silverlight/#Diagrams/OrgChart. The OrgChart will be shown in a SharePoint WebPart.
    i have already changed the way of inputting data in here. My data come from a SharePoint 2010 List with the help of
    clientcontext.ExecuteQueryAsync(OnSuccess, OnFailed);  The Method OnSuccess gives the data within a customize class type back to OrgChartViewModel with the help of Deployment.Current.Dispatcher.BeginInvoke(() => _callBack(rootPerson));
    Now the Problem is, that the UI Thread is running further and try to create the connections and binding the initial positions of the nodes (with not the correct Data in there).
    I have found

     

    http://www.telerik.com/community/forums/silverlight/diagram/orgchart-example.aspx this thread in the forum, but i think i have not quite the same problem. Because it is putting some positions and connections, but not with the complete HierarchicalDataSource.

    Is here maybe someone who knows this huge code project good enough, that can say which ViewModel or Links i must restart after i came back from my clientcontext thread?
    Or is there a chance for stopping the UI thread until my getting data thread is ready?

    Your sincerely

  2. Answer
    Pavel R. Pavlov
    Admin
    Pavel R. Pavlov avatar
    1182 posts

    Posted 17 Jan 2014 Link to this post

    Hi,

    As far as I understand your scenario, you need to load the GraphSource of the RadDiagram control asynchronously. It is most likely that when the GraphSource is loaded the data is not yet populated and the rendered shapes are not visualized correctly.

    In order to overcome this issue you need to make sure that your business data is properly loaded before visualizing the GraphSource will work as expected. For your convenience we created a sample project demonstrating how you can use an event to make sure that the data is loaded.

    Please take a look at the OrgChartViewModel.cs file and let us know if you need any further assistance.

    Regards,
    Pavel R. Pavlov
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. DevCraft banner
  4. Helga
    Helga avatar
    3 posts
    Member since:
    Jan 2013

    Posted 28 Jan 2014 in reply to Pavel R. Pavlov Link to this post

    Dear Pavel,

    thanks a lot for your answer. I figured out, how i could fix my problem.
    There was only one thing: it looks like we have used complete different versions of the example project. In mine there is for example no ItemDisplayMode, there is still all the stuff in OrgTeamViewModel and there is still the OrgTeamMemberViewModel existing. (Mine is the version that is shown in http://demos.telerik.com/silverlight/#Diagrams/OrgChart)

    Because it would need so much time to change all the stuff, so that it will work. We decided to use the telerik asp.net OrgChart in RadOrgChart and not the silverlight one.

    With best regards
  5. Bala
    Bala avatar
    20 posts
    Member since:
    Dec 2011

    Posted 07 Feb 2014 in reply to Pavel R. Pavlov Link to this post

    Hi,

        Is it possible to export the entire content to xml & import it back  in same format as is in the form of raddiagramshapes.
  6. Pavel R. Pavlov
    Admin
    Pavel R. Pavlov avatar
    1182 posts

    Posted 11 Feb 2014 Link to this post

    Hi Bala,

    Yes. You are allowed to export the RadDiagram in XML and after that to import it again. This functionality is provided by the Serialization feature of the control. You can find more information in our documentation. Our FirstLook example demonstrates how this feature can be implemented.

    I hope this information is helpful. Please do not hesitate to ask if you need any further assistance.

    Regards,
    Pavel R. Pavlov
    Telerik

    Check out the new Telerik Platform - the only modular platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native apps. Register for the free online keynote and webinar to learn more about the Platform on Wednesday, February 12, 2014 at 11:00 a.m. ET (8:00 a.m. PT).

Back to Top
DevCraft banner