How to force a Canvas to Measure RRS feed

  • Question

  • Hello!

    I'm making a WPF application which load WPF user controls in run time from a xaml file, these controls are added to a canvas panel. When I try to get ActualWidth or ActualHeight are zero( 0 ). Reading on web how to force to get a value for ActualWidth and ActualHeight the sugestion was to call 2 methods: Measure and Arrange. I did this but no success. Using .net reflector I check what do method "Measure" and it seems it return always "new Size()"

    I was tried the same scenario with a grid and return values for ActualWidth and ActualHeight.

    It is correct or it is a bug? How can I measure a canvas?
    • Moved by Brent Serbus Thursday, December 10, 2009 6:36 AM needs a home (From:Forums Issues (not product support))
    Friday, December 4, 2009 12:58 PM