Toto je starší verze dokumentu!


WPF

XAML

Obrázky v ručně čteném XAMLu jako Resource, a v kódu nastavit Application.ResourceAssembly na assembly která resource obsahuje.

ActualWidth je nulový

That this is due to the fact that the measure and arrange pass has not executed yet. However, rather than force another layout pass (expensive), you can just wait until your control has loaded before accessing the ActualXxx properties:

public MyWindow()
{
    Loaded += delegate
    {
        // access ActualWidth and ActualHeight here
    };
}
programovani/wpf.1331889491.txt.gz · Poslední úprava: 16.03.2012 10:18 autor: wladik

Nástroje pro stránku