我如何使用sql server在asp.net C#中使用category,sub category,inner category和innersubcategory生成树视图 [英] how I generate tree view with category, sub category,inner category and innersubcategory in asp.net C# by using sql server

查看:64
本文介绍了我如何使用sql server在asp.net C#中使用category,sub category,inner category和innersubcategory生成树视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使用sql-server在asp.net C#中生成具有类别,子类别,内部类别和内部子类别的树视图?如果类别表具有ID,Parent_id和名称。我还希望下载并上传execelsheet选项到特定的子类别,每个主类别类别都有自己的复选框。

类别1

-subcategory 1.1下载和上传excel

类别2

-subcategory 2.1

--innercategory 2.1.1下载和上传excel

-subcategory 2.2下载和上传excel

-subcategory 2.3下载和上传excel

类别3

-subcategory 3.1

- 内阁类别3.1.1

--inner子类3.1.1.1下载和上传excel

- 内阁类别3.1.2下载和上传excel

- -inner类别3.1.3下载和上传excel

-subcategory 3.2下载和上传excel

-subcategory 3.3下载和上传excel

类别4下载并上传excel

how can I generate tree view which have category, sub category,inner category and inner-subcategory in asp.net C# by using sql-server? If category Table have ID,Parent_id and name. I also want to give download and upload execelsheet option to particular child category and each Main category category have its own checkbox.
Category1
-subcategory 1.1 download and upload excel
Category 2
-subcategory 2.1
--innercategory 2.1.1 download and upload excel
-subcategory 2.2 download and upload excel
-subcategory 2.3 download and upload excel
Category 3
-subcategory 3.1
--inner category 3.1.1
--inner subcategory 3.1.1.1 download and upload excel
--inner category 3.1.2 download and upload excel
--inner category 3.1.3 download and upload excel
-subcategory 3.2 download and upload excel
-subcategory 3.3 download and upload excel
Category 4 download and upload excel

推荐答案

check ^ ]


你不能生成树视图...使用SQL服务器,因为SQL服务器与UI视图无关,它们只处理数据。有关树视图,请参阅:

https://msdn.microsoft.com/en-us/library/d4fz6xk2%28v=vs.80%29.aspx [ ^ ],

https://msdn.microsoft.com/en-us/library/ system.web.ui.webcontrols.treeview%28v = vs.110%29.aspx [ ^ ],

http://quickstarts.asp.net/quickstartv20/aspnet/doc/ctrlref/navigation/treeview.aspx [ ^ ]。



我不知道你还需要帮助。为了在关系数据库中表示树结构,你只需要基本的,非常基本的关系模型知识,在ASP.NET方面你需要ADO.NET,我想,ASP.NET基础知识。



-SA
You cannot "generate a tree view… using SQL server", because SQL servers have nothing to do with UI views, they only deal with data. For the tree view, please see:
https://msdn.microsoft.com/en-us/library/d4fz6xk2%28v=vs.80%29.aspx[^],
https://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.treeview%28v=vs.110%29.aspx[^],
http://quickstarts.asp.net/quickstartv20/aspnet/doc/ctrlref/navigation/treeview.aspx[^].

I don't know else would you possibly need for help. For representing tree structures in a relational database, you just need basic, very basic knowledge of relational model, and on the ASP.NET side you need ADO.NET and, I guess, ASP.NET basics.

—SA


这篇关于我如何使用sql server在asp.net C#中使用category,sub category,inner category和innersubcategory生成树视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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