我想为我的网站中的不同页面制作不同的标签 [英] i want to make different tabs for different pages in my website

查看:71
本文介绍了我想为我的网站中的不同页面制作不同的标签的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我已经在Google上搜索了有关我的Web应用程序标签"的信息.

但我没有得到令人满意的答案.选项卡组件没有控制.

请告诉我如何在网页中创建标签,以便可以在每个标签上打开不同的页面.


谢谢.....

如果您能在C#中为我提供一个小示例,我将不胜感激.

在您的主面板中,您可以继续添加.NET TabItem以在其中获得"tab"效果您的Web应用程序.这是示例代码:


 私有  void  btnTabSimuate_Click(对象发​​件人,RoutedEventArgs e)
{
    mainHostPanel.Items.Add(CreateTabWeb());
}

私有 TabItem CreateTabWeb()
{
    TabItem tabItem =  TabItem();
    tabItem.Header = " ;
    tabItem.Content =  DoView();
    tabItem.Tag = " ;
    tabItem.MinWidth =  90 ;
    tabItem.BorderThickness = 厚度( 0 );
    tabItem.Style = Application.Current.Resources [" ] 返回 tabItem;
}


hi,


i have searched on google about the "tab" for my web application.

but i m not getting the satisfectory answer. there is no control for tab component.

please tell me how can i create tab in my web page so that i can open different page on each tab.


thanks.....

i would appriciate if you can provide me a small example in C#

解决方案

In your main panel, you can keep adding a .NET TabItem to get "tab" effect in your web application. Here is the sample code:


private void btnTabSimuate_Click(object sender, RoutedEventArgs e)
{
    mainHostPanel.Items.Add(CreateTabWeb());
}

private TabItem CreateTabWeb()
{
    TabItem tabItem = new TabItem();
    tabItem.Header = "Header On Tab";
    tabItem.Content = new DoView();
    tabItem.Tag = "Tag";
    tabItem.MinWidth = 90;
    tabItem.BorderThickness = new Thickness(0);
    tabItem.Style = Application.Current.Resources["MyStyle"] as Style;
    return tabItem;
}


这篇关于我想为我的网站中的不同页面制作不同的标签的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆