Hi Friends,
While developing the application in Windows Presentation Foundation, you might face with issue of scaling the application. If you want to run your application into different display of different resolutions then you might need to scale up/down your application to regain the application controls at the right position as they were present before.
- For the resolution Independence of application, you should place your into the ViewBox which defines a content decorator that can stretch and scale a single child to fill the available space.
- In this way, whenever you will re-size the window, your application controls will also re-size with the same aspect ratio and automatically will get stretched and scaled properly.
- If you are using Expression Blends, then a snapshot of Objects and Timeline is added for your referral as how to add the controls in viewbox.
- In the figure above, Grid contains all the controls which are used inside the application and the same grid is placed inside the viewbox control which is included in the main window.
Enjoy






