0

Actually, I'm a very new developer of WPF (I didn't do anything in this technology for almost 5 years) and now I started working in a new application using ModernUI.

My problem is that I don't know how to use templates (Pages). Because I'm missing properties from WinForms like Anchor or Dock.

By this reason, the new page I created doesn't fit correctly to my MainWindow. I see this two property that can be added to my UserControl "page":

Width="{Binding Path=ActualWidth, ElementName=MainWindow}" 
Height="{Binding Path=ActualHeight, ElementName=MainWindow}"

And it works. But does the following two my view:

...

If I remove this to the default value:

...

I would like to see control streching to its in a correct way.

Also, when I develop with WinForms + DevExpress + UserControls I didn't have any problem to do interfaces, because I used TableLayouts, but there aren't any control or equivalent control. So I have to use Grids... But they are confusing and compilcated, when in WinForms is a very easy way of editing it. I'm missing something from this too?

z3nth10n
  • 2,341
  • 2
  • 25
  • 49
  • believe me wpf has more fun than winForm. By default usercontrol occupy entire space of parent, until you define width/height. Anyhow if it still not working, you can set horizontalAlignment/VerticalAlignment to "Stretch". It would be better if you share sample code. – Kamran Asim Jan 10 '19 at 04:36
  • You need to post your code and markup for anyone to be able to help you. Please read [this](https://stackoverflow.com/help/mcve). – mm8 Jan 10 '19 at 12:31

0 Answers0