FrameworkContentElement.IsLoaded Property


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Gets a value indicating whether this element has been loaded for presentation.

Namespace:   System.Windows
Assembly:  PresentationFramework (in PresentationFramework.dll)

Public ReadOnly Property IsLoaded As Boolean

Property Value

Type: System.Boolean

true if the current element is attached to an element tree and has been rendered; false if the element has never been attached to a loaded element tree.

From a newly constructed instance, this property starts off false, and remains true once it is set to true, even if subsequently removed by code.

The following example code uses IsLoaded as a conditional check to assure that a function displayData (not shown) will have valid elements loaded on the page to work against, as part of an on-demand handler. That same logic is run as an event handler for Loaded.

Private Sub OnLoad(ByVal sender As Object, ByVal e As RoutedEventArgs)
End Sub
Private Sub updateSummary(ByVal sender As Object, ByVal e As RoutedEventArgs)
 If myflowdocument.IsLoaded Then
 End If
End Sub

.NET Framework
Available since 3.0
Return to top