OnControlAddin Issue

2 posts, 0 answers
  1. Martin
    Martin avatar
    2 posts
    Member since:
    Mar 2015

    Posted 17 Apr 2015 Link to this post

    hello guys,

    i'm testing this control for developing a gantt for ms dynamics nav. Everything works fine but now i'm searching for a way to manually update the whole view, because i load data async nothing is shown in my gantt when it's loaded on my page. I want the control to completely update it's view when dataload is finished and i don't know which function to use or how to do this.


    As u can see in pic1 page is open no data is shown.

    As u can see in pic2 i only resize width a little bit, ganttPart is updated.

    As u can see in pic3 i resize width an height more, gridPart is also updated.

    i need a function to do the update, when my dataset i loaded.


  2. Polya
    Polya avatar
    193 posts

    Posted 20 Apr 2015 Link to this post

    Hi Martin,

    The issue might lie as the RadGanttView.TasksSource is not notified when the data is loaded.
    I suggest binding the RadGanttView.TasksSource to a collection that notifies when it is populated.

    I've prepared a sample project demonstrating this approach. Take a look at the Tasks property in the ViewModel class. Whenever it is being set to a new collection it notifies for change.
    I've added a button - "Populate tasks" that sets the ViewModel.Tasks to a new ObservableCollection<IGanttTask> and bind the TasksSource to Tasks:
    <telerik:RadGanttView Grid.Row="1" TasksSource="{Binding Tasks}" VisibleRange="{Binding VisibleRange}" x:Name="gantt">

    Hopefully this helps.


    See What's Next in App Development. Register for TelerikNEXT.

  3. DevCraft banner
Back to Top