我想在ASP.NET网页上动态显示产品。如果产品信息和图标存储在SQL Server数据库中,我该怎么做? [英] I want to display products dynamically on a ASP.NET web page. How can I do this if the product information and icon is stored in SQL server database ?

查看:54
本文介绍了我想在ASP.NET网页上动态显示产品。如果产品信息和图标存储在SQL Server数据库中,我该怎么做?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只是想知道如何在.apsx网页中动态添加内容(这里的产品卡像flipkart)。



我尝试了什么:



我尝试了一个固定的布局,比如10 X 10的HTML表。但这不是我认为的最佳解决方案。

I just want to know how to add contents(here products card like flipkart) dynamically in .apsx webpage.

What I have tried:

I tried a fixed layout , say a 10 X 10 HTML table. But this is not the optimal solution as i think.

推荐答案

您可以使用Repeater或DataList控件来满足要求。运行查询以从数据库中检索所需的信息,然后通过将数据绑定到控件来将其填充到控件中。
You can use Repeater or DataList controls for the requirement. Run a query to retrieve the information required from database and then just populate those to the control by binding data to it.


这篇关于我想在ASP.NET网页上动态显示产品。如果产品信息和图标存储在SQL Server数据库中,我该怎么做?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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