如何显示在asp.net标签控件 [英] How to show tab control in asp.net

查看:131
本文介绍了如何显示在asp.net标签控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发使用.NET Framework 4.0的C#.NET Web应用程序。

I am developing a C# .NET web application using .NET Framework 4.0.

在这一点,我需要显示一个页面3个标签像我们的网页浏览器做的。每个标签都有一个不同的功能。

In that, I need to show a page with 3 tabs like our web browsers do. Each tab has a different functionality.

如何创建在使用.NET Framework 4.0的Visual Studio的标签控制,有没有内置的标签控件?

How can I create tab control in Visual Studio using the .NET Framework 4.0, is there any built in tab controls?

关于

推荐答案

还有的AJAX控件工具包的标签的jQuery UI选项卡。我都用了和preFER jQuery用户界面。微软正式包括/建议jQuery的web应用程序。

There's the AJAX control toolkit tabs and jQuery UI tabs. I have used both and prefer jQuery UI. Microsoft officially includes/recommends jQuery with web applications.

我也认为这些滑动片看pretty的不错(虽然有一个小的许可费)。

I also think that these sliding tabs look pretty nice (though there is a small license fee).

如果每个标签具有完全独立的内容,我会建议心碎的环节简单,风格的酒吧,并有每一个元素链接到一个新的页面/视图。这样一来,隐藏的内容不渲染,直到它的需要。

If each tab has completely separate content, I would suggest rending a simple, styled bar of links and have each element link to a new page/view. That way, hidden content isn't rendered until it's needed.

请注意,这并没有什么关系或Visual Studio;这是一个纯粹的客户端解决方案。

<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jqueryui/1.8.18/jquery-ui.min.js"></script>

<script>

$(function() {
    $( "#tabs" ).tabs();
});

</script>

<div id="tabs">
    <ul>
        <li><a href="#tabs-1">Tab 1</a></li>
        <li><a href="#tabs-2">Tab 2</a></li>
        <li><a href="#tabs-3">Tab 3</a></li>
    </ul>
    <div id="tabs-1">Content 1</div>
    <div id="tabs-2">Content 2</div>
    <div id="tabs-3">Content 3</div>
</div>

这篇关于如何显示在asp.net标签控件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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