有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

java如何在使用显示标记导出到Excel时删除单选按钮?

我想导出在jsp页面上使用display标记显示的表。 但当我导出它时,它会导出带有表格的单选按钮

下面是显示标记的片段

<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文件中不应包含单选按钮


共 (1) 个答案

  1. # 1 楼答案

    问题解决了 在包含单选按钮的显示列标记中,我放置了media=“html”,现在它不会在excel工作表中导出单选按钮

    在上述代码段中更改的代码::

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