Skip to content

Infragistics Community Forum / Cross Platform / Ultimate UI for Xamarin / BusyIndicator not displaying when view is displayed inside a XamDialogWindow

BusyIndicator not displaying when view is displayed inside a XamDialogWindow

New Discussion
Chris Forman
Chris Forman asked on Jun 22, 2012 9:45 AM

We have the following view:

<UserControl x:Class="DetailedSalesView" ...
  <Grid x:Name="LayoutRoot">
    <toolkit:BusyIndicator x:Name="activityControl"
                                   IsBusy="{Binding IsBusy}"
                                   BusyContent="{Binding}" >
         <Grid>
             The rest of the control
            </Grid>
        </toolkit:BusyIndicator>
    </Grid>
</UserControl>

When this is instantiated normally the busy indicator appears as expected. The view model implements `INotifyPropertyChanged` and has the property `IsBusy` which gets set at the appropriate places.

We are trying to display this same view in a XamDialogWindow and everything is working except for the BusyIndicator.

The code we have is:

    this._eventAggregator = container.Resolve<IEventAggregator>();

Where `container` is an `IUnityContainer`

    var childViewModel = new DetailedSalesVM(dataService, _eventAggregator);
    var childView = new DetailedSalesView(_eventAggregator, childViewModel);

    var window = new XamDialogWindow
    {
        Width = 800,
        Height = 600,
        Content = childView,
        StartupPosition = StartupPosition.Center,
        Header = headerText
    };

    parent.Children.Add(window);

Where `dataService` is a class that implements the RIAServices connection to the database, and `parent` is the `UIElement` we wish to display the dialog window in.

The view populates correctly and the `IsBusy` property on the view model is set as expected, but the `BusyIndicator` just doesn’t display.

What are we missing?

Sign In to post a reply

Replies

  • 0
    Chris Forman
    Chris Forman answered on Jun 1, 2012 2:06 PM

    I've done some further investigation and have found the following:

     

    • The notification of the `IsBusy` property changing value is definitely getting to the view.
    • If I hard code the `BusyIndicator` to be `Busy` it still doesn't appear, but the contents of the view (in this case a `XamGrid` are no longer selectable (I can't select the grid cells or row).
    • Swapping the `XamGrid` for other, simpler, controls such as a `TextBlock` or `Button` shows exactly the same behaviour.
    • In fact careful examination reveals that the content is in fact disabled during the period when the `BusyIndicator` should be visible.
    • We're using a custom style for the `BusyIndicator` but even when I remove this I get the same behaviour.

     

    This leads me to think that the `BusyIndicator` is getting shown but is for some reason completely transparent.

  • 0
    Chris Forman
    Chris Forman answered on Jun 11, 2012 4:02 PM

    I have created a simple project that reproduces this issue. I’ve uploaded the file to my Google Drive folder.

    It just consists of a main page with a single button that opens the child window whose contents (another button) are wrapped in a busy indicator. In this version the busy indicator is permanently on and you can see that that the button is greyed out but the busy indicator is not visible.

    • 0
      Benji Vesterby
      Benji Vesterby answered on Jun 12, 2012 5:24 PM

      I am also having this issue, has anyone found a solution?

  • 0
    Stefan
    Stefan answered on Jun 22, 2012 9:45 AM

    Hello Chris,

    It has been a while since you have made your post, in case you still need support I will be glad to assist you further. I suppose the other community members can benefit from this answer as well. I have been looking into your post and I modified your sample, so now it works as you want. Basically I used Dispatcher to set the Content of the XamDialogWindow, because the BusyIndicator renders faster and it seems like that it remains below the Window.

    Feel free to write me if you have further questions.

  • You must be logged in to reply to this topic.
Discussion created by
Favorites
Replies
Created On
Last Post
Discussion created by
Chris Forman
Favorites
0
Replies
4
Created On
Jun 22, 2012
Last Post
14 years, 3 months ago

Suggested Discussions

Created by

Created on

Jun 22, 2012 9:45 AM

Last activity on

Feb 19, 2026 9:05 PM