I am trying to develop a program that has the possibility to adapt at the screen resolution of the user.
I am using mvvm with the pushbinding of Meleak to obtain the actual size of my MainWindow:
Getting Window Properties in ViewModel
For positioning my object, I am using GridRow
and GridColumn
. Now I am trying to optimize this size, for that I have the need to get the ActualSize
of my other UIElment
, but like their size depend of their contents, I don't know how I can get their size, I try with a binding onewaytosource but I obtain a size of 0.0 and obviously is not the size after initialisation.