Hi All,
I am new to WPF XAML, below is something i tried & stuck in displaying new/another xaml file.
1) In the window.xaml file i created 2 rows & 2 column.
2) in row = 0 + col=0 & row=0 + col=1, i created a button in xaml added event handler in code behinde. in row = 0 + col=1 i created another button.
3) Now i created seperate two xaml files with some controls in it.
4) I want to display these xaml file(s) when user clicks on a button 1, and this xaml file should be displayed in row=1 + col = 1
5) when user clicks 2nd button one of the xaml file should be displayed in the same grid.row=1 + col=1, the prev xaml file shall be closed and save into some History collection list.
Please help in implementing it,
Thanks & Regards.,
Naresh.
Tom MohanPosted Apr 5, 2015, 12:05 PM
I have updated test application. PFA. I hope you got the solution.
Naresh KPosted Apr 5, 2015, 11:51 AM
Thank you for reply,
i have separeate *.xaml files created, when i click on "button 1" 1.xaml should display in grid.row=1 grid.col=1. And at the same time if i click on "button 2" 2.xaml should display in same grid.row=1 grid.col=1. is it done in code behind or we can do it in only xaml files.
The area(grid.row=1 grid.col=1) should be like a frame/view where on click of any button any xaml file should display. or i want a dynamically displaying the xaml files at this location. so i can't relay on adding all the number of xaml files in that grid & use show/hide on respective buttons click.
I hope i made my point clear, Thank you for you time in helping me understand WPF XAML.
Thanks & Regards.,
Naresh
Tom MohanPosted Apr 5, 2015, 10:37 AM
I have created one sample project for your requirement with my understanding. PFA
Tom MohanPosted Apr 5, 2015, 10:24 AM