English 中文(简体)
Grid View withdictionary as datasource
原标题:Grid View with dictionary as datasource

请帮助我...... 我需要把词典作为数据来源列入GridView。 字典含有诸如特性开始和完成等物体。 我只找到了数据集、结果、q调器等与格里德意见相连接的信息。

GridView试图向我提出字典,也应当成为一种可调的词,但我怀疑第1号问题只是将其联系起来。

最佳回答
问题回答

如果你只是把数据来源确定为数据来源,并且为真实情况确定一个简便的栏目,那将做些微的工作。 如果你想要对各栏进行明确约束,那么你就会将其与钥匙和价值特性联系起来。 e.g:

<asp:GridView runat="server" ID="MyGridView" AutoGenerateColumns="false">
     <Columns>
         <asp:BoundField DataField="Key" />
         <asp:BoundField DataField="Value" />
     </Columns>            
</asp:GridView>




相关问题
Anyone feel like passing it forward?

I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Transaction handling with TransactionScope

I am implementing Transaction using TransactionScope with the help this MSDN article http://msdn.microsoft.com/en-us/library/system.transactions.transactionscope.aspx I just want to confirm that is ...

System.Web.Mvc.Controller Initialize

i have the following base controller... public class BaseController : Controller { protected override void Initialize(System.Web.Routing.RequestContext requestContext) { if (...

Microsoft.Contracts namespace

For what it is necessary Microsoft.Contracts namespace in asp.net? I mean, in what cases I could write using Microsoft.Contracts;?

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签