如何在asp.net c中转发html表以在excel中导出 [英] how to repeater html table to export in excel in asp.net c#
本文介绍了如何在asp.net c中转发html表以在excel中导出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
<asp:Repeater runat="server" ID="detailview" EnableViewState="false" Visible="false" >
<HeaderTemplate>
<table class="table table-hover table-bordered tablesorter" id="tbdetails">
<tr>
<th> Agent Name </th>
<th> Date </th>
<th> Customer Name </th>
<th> Payment Type </th>
<th> Check No </th>
<th> Amount </th>
</tr>
</HeaderTemplate>
<ItemTemplate>
<tr>
<td id="agtname"><%# ((tablname)Container.DataItem).Agent_name %></td>
<td id="Td1"><%# ((tablname)Container.DataItem).datesale %></td>
<td id="custname"><%# ((tablname)Container.DataItem).Customer_Name %></td>
<td id="trantype"><%# ((tablname)Container.DataItem).Transaction_type %></td>
<td id="chk"><%# ((tablname)Container.DataItem).Check_no %></td>
<td id="amt" style="text-align:right;"><%# ((tablname)Container.DataItem).Amount %></td>
</tr>
</ItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
推荐答案
试试这些链接 -
将ASP.Net Repeater Control导出到Excel文件 [ ^ ]
将数据从Repeater / Datagrid导出到Excel [ ^ ]
将gridview或repeater导出到Excel [ ^ ]
Try these links -
Export ASP.Net Repeater Control to Excel File[^]
Export Data from Repeater/Datagrid to Excel [^]
Export gridview or repeater to Excel[^]
这篇关于如何在asp.net c中转发html表以在excel中导出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文