c# - Using LinqToExcel to Create XML -
i'm trying build xml file excel spreadsheet (no header row). part of service on server, don't want use ms office pio files. found linqtoexcel on google , tried code:
var clientexcel = new excelqueryfactory(excelfilename); var sourcexml = new xelement("rows", clientexcel.worksheetnoheader().select(line => new xelement("row", line.select((column, index) => new xelement("column_" + index, column))))); the code compiles, @ runtime targetinvocationexception. i've worried @ better part of day, can't figure out i've gone wrong.
i'd appreciate if set me straight.
...if u enable developer menu in excel, there's 'export xml' option in 2003 done easy save > .xml in 2007 u might need prepare mapping schema. still better write codes u dont know data header
Comments
Post a Comment