Ray
Ray

Reputation: 4947

Show DevExpress DXTabControl tabs at the bottom in XAML

Does anyone know how to use the DevExpress DXTabControl in XAML and set it up so that the tabs appear at the bottom? Here is what I have so far but the tabs show up at the top. The DevExpress documentation does not have an example of this. Intellisense does not give me anything intuitive.

<dx:DXTabControl>
    <dx:DXTabItem Header="Main">
        <dxdo:DockLayoutManager>
            <dxdo:LayoutGroup>
                <dxdo:LayoutPanel Caption="TaskList">
                    <views:DxTaskList x:Name="Tasklst" />
                </dxdo:LayoutPanel>
                <dxdo:LayoutPanel Caption="TaskDetails">
                    <ScrollViewer VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" Focusable="False">
                        <StackPanel>
                            <views:TaskDetails x:Name="TaskDtls"/>
                        </StackPanel>
                    </ScrollViewer>
                </dxdo:LayoutPanel>
            </dxdo:LayoutGroup>
        </dxdo:DockLayoutManager>
    </dx:DXTabItem>
</dx:DXTabControl>

Upvotes: 2

Views: 2160

Answers (1)

Ray
Ray

Reputation: 4947

For anyone who might be stumped at something not-so-obvious, here is the XAML solution I was looking for. Yes, the property was obviously called HeaderLocation but DevExpress' documentation does not give any XAML examples on this. So here is what I came up with that solved my case:

<dx:DXTabControl>
    <dx:DXTabControl.View>
        <dx:TabControlMultiLineView HeaderLocation="Bottom"/>
    </dx:DXTabControl.View>
    <dx:DXTabItem Header="Main">
        <dxdo:DockLayoutManager>
            <dxdo:LayoutGroup>
                <dxdo:LayoutPanel Caption="TaskList">
                    <views:DxTaskList x:Name="Tasklst" />
                </dxdo:LayoutPanel>
                <dxdo:LayoutPanel Caption="TaskDetails">
                    <ScrollViewer VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" Focusable="False">
                        <StackPanel>
                            <views:TaskDetails x:Name="TaskDtls"/>
                        </StackPanel>
                    </ScrollViewer>
                </dxdo:LayoutPanel>
            </dxdo:LayoutGroup>
        </dxdo:DockLayoutManager>
    </dx:DXTabItem>
</dx:DXTabControl>

As you can see you're supposed to add the View property and then assign it a value, which I used a TabControlMultiLineView, and that object had a HeaderLocation property to which I set it to one of the valid enums. When I did this, the tabs appeared at the bottom.

Upvotes: 8

Related Questions