How to implement Tab Control in wpf application?

Leave a Comment
Create Tab control in wpf. It's very easy to create tab in wpf rather than web. Here i will give you comple demo source code with code snippets for tab control.

Main Window
<Window x:Class="TabControlinWpf.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MainWindow" Height="350" Width="525">
    <TabControl>
        <TabItem Header="Tab1">
            This is tab1
        </TabItem>
        <TabItem Header="Tab2">
            This is tab2
        </TabItem>
        <TabItem Header="Tab3">
            This is tab3
        </TabItem>
        <TabItem Header="Tab4">
            This is tab4
        </TabItem>
        <TabItem Header="Tab5">
            This is tab5
        </TabItem>
       
    </TabControl>
</Window>
After putting this code in design file you will get output for tab like this,



0 comments:

Post a Comment