如何为xsl:text设置固定长度?

时间:2019-04-03 03:24:57

标签: xml xslt

我正在使用XSLT创建固定宽度的CSV文件。我在您的文件中包含标题,并按如下所示创建了它们:

 <xsl:template match="wd:Report_Data">
 <xsl:text>"Group Number","User ID","Social Security     Number","Employee ID","Relation","First Name","Middle Initial",Last Name","Employee Status","Hire Date","Termination Date","Termination Reason","Job Title","Salary","Hourly Rate","Hours Per Week","Benefits Base Salary","Compensation Date","Date of Birth","Gender","Home Address Line 1","Home Address Line 2","City","State","Postal Code","Country","Work Email","User Name","Time Type","Worker Type","Company"</xsl:text>
<xsl:for-each select="wd:Report_Entry">

在输出CSV文件中,标题未正确对齐。我们如何将标题与固定长度对齐?

示例:组号(额外的20个空格),用户ID(额外的10个空格)等

谢谢

0 个答案:

没有答案