首页 | 编程语言 | 网站建设 | 游戏天堂 | 冲浪宝典 | 网络安全 | 操作系统 | 软件时空 | 硬件指南 | 病毒相关 | IT 认证
软讯网络 > 网站建设 > ASP.NET > Nested DataLists (C# Version)
【标  题】:Nested DataLists (C# Version)
【关键字】:C#,C,io,Nested,DataLists,Version
【来  源】:http://www.aspnet101.com/aspnet101/aspnet/codesample.aspx?code=nestedc

Nested DataLists (C# Version)

Code Sample for Nested DataLists (C# Version) Sometimes, we need to nest data - say for instance - List the Categories, and under each Category, list the Products for that particular Category. This sample uses the SQL Managed Provider to show exactly that, using the Categories and Products tables from the NorthWind Database. As usual, just copy this code directly into a new page, change the database/connection information to match your system, and run it from your own computer. You can read a Tutorial about this code here. Thanks to Mike Houston for this code sample http://www.nexus6studio.com See this code in VB.Net -------------------------------------------------------------------------------- Here's the Code: <%@ Import Namespace="System.Data" %> <%@ Import Namespace="System.Data.SqlClient" %> Nested Datalists Using C#
Categories & Products <%# DataBinder.Eval(Container, "DataItem.CategoryName") %>
    <%# DataBinder.Eval(Container, "DataItem.ProductName") %>
利用ASP.NET DataGrid显示主次关系的数据:【上一篇】
用datalist实现四层嵌套:【下一篇】
【相关文章】
没有相关文章
【随机文章】
  • 学习Python(10)- Function(默认参数)
  • 计算两个日期时间之间相差秒数的代码
  • DreamWeaver高级应用—模板与库
  • 关于lslpp命令
  • Vnc的远程安装
  • ACE中的设计模式(1)——Singleton
  • 最袖珍的垃圾回收器
  • C/C++中嵌入Lua--转自bbs.luachina.net
  • 小小宝和我的第一次接触
  • fastdb 延迟事务和在线备份调度
  • 【相关评论】
    没有相关评论
    【发表评论】
    姓名:
    邮件:
    随机码*
    评论*
          
    |  首 页  |  版权声明  |  联系我们   |  网站地图  |
    CopyRight © 2004-2007 软讯网络 All Rigths Reserved.