2012-02-08 29 views
3

我想導出在jsp頁面上使用顯示標籤顯示的表格。 但是,當我出口,它出口單選按鈕與表如何使用顯示標籤導出到Excel時刪除單選按鈕?

下面是顯示標籤

<display:table requestURI="CustListReportDetails.do" name="sessionScope.SESSION_CUST" id="formtable" pagesize="100" style="width:100%; border:0; cellspacing:0; cellpadding:10; align:center;" export="true"> 

    <display:table requestURI="CustListReportDetails.do" name="sessionScope.SESSION_CUST" id="formtable" pagesize="100" style="width:100%; border:0; cellspacing:0; cellpadding:10; align:center;" export="true"> 
    <display:column title="" style="width:10px"> 
     <input type="radio" name="recordIdentifier" value="${formtable.customerId}" onclick="javascript:setRoleCode('${formtable.customerId}');"/> 
    </display:column> 
    <display:column property="name" title="Name" /> 
    <display:column property="contactPerson" title="Contact Person" />    
    <display:column property="gender" title="Gender" /> 
    <display:column property="dob" title="Date Of Birth" /> 

    <display:setProperty name="export.excel.filename" value="Customer_reportExcel.xls" /> 
</display:table> 

所需的XSL文件不應該有它的單選按鈕的片段。

+0

我很沮喪的同樣的問題,所以我轉移到[這個dataTables插件](http://datatables.net/)。它使用正常的html表格格式,並具有無限的功能。此外,它不會重新加載排序,分頁等頁面。試一試 – anu 2012-02-08 07:07:17

+0

仍然使用JSP? – 2012-02-08 09:49:04

回答

3

的問題得以解決 在顯示欄標籤含有單選按鈕,我已經把媒體=「HTML」,現在,它不會在excel表

代碼在上面的代碼片段改變導出的單選按鈕: :

display:column title="" style="width:10px" **media="html"**