Probably don't have the right forum here, but this is all a bit new to me. I have a web site that sends me a daily email with an excel spreadsheet attachment that contains some customer data. Sadly, now that I am using Excel 2007, I can't open the file for some reason. The code I am using to generate the file is below. Am I missing something obvious as it opens fine in Excel 2003. I am asking here as I think it's javascript, but I'm probably wrong on that one! Code below.
Any help much appreciated!
Thanks,
Nick
Expand|Select|Wrap|Line Numbers
- {startXml:h}
- <Workbook xmlns="urn:schemas-microsoft-com:office:spreadsheet"
- xmlns:o="urn:schemas-microsoft-com:office:office"
- xmlns:x="urn:schemas-microsoft-com:office:excel"
- xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"
- xmlns:html="http://www.w3.org/TR/REC-html40">
- <DocumentProperties xmlns="urn:schemas-microsoft-com:office:office">
- </DocumentProperties>
- <OfficeDocumentSettings xmlns="urn:schemas-microsoft-com:office:office">
- <DownloadComponents/>
- </OfficeDocumentSettings>
- <ExcelWorkbook xmlns="urn:schemas-microsoft-com:office:excel">
- <WindowHeight>9345</WindowHeight>
- <WindowWidth>11340</WindowWidth>
- <WindowTopX>480</WindowTopX>
- <WindowTopY>60</WindowTopY>
- <ActiveSheet>0</ActiveSheet>
- <ProtectStructure>False</ProtectStructure>
- <ProtectWindows>False</ProtectWindows>
- </ExcelWorkbook>
- <Styles>
- <Style ss:ID="Default" ss:Name="Normal">
- <Alignment ss:Vertical="Bottom"/>
- <Borders/>
- <Font ss:FontName="Arial"/>
- <Interior/>
- <NumberFormat/>
- <Protection/>
- </Style>
- <Style ss:ID="s21" ss:Name="Link">
- <Font ss:FontName="Arial" ss:Color="#0000FF"
- ss:Underline="Single"/>
- </Style>
- <Style ss:ID="s28">
- <Font ss:FontName="Arial" ss:Bold="1"/>
- </Style>
- <Style ss:ID="s32">
- <NumberFormat ss:Format="[$$-409]#,##0.00"/>
- </Style>
- <Style ss:ID="s35">
- <NumberFormat ss:Format="Short Date"/>
- </Style>
- <Style ss:ID="s37">
- <Font ss:FontName="Arial" ss:Bold="1"/>
- <NumberFormat ss:Format="Short Date"/>
- </Style>
- <Style ss:ID="s39">
- <Font ss:Bold="1"/>
- <NumberFormat ss:Format="[$$-409]#,##0.00"/>
- </Style>
- </Styles>
- <Worksheet ss:Name="customers">
- <Table ss:ExpandedColumnCount="22" x:FullColumns="1" x:FullRows="1">
- <!-- <Row>
- <Cell ss:StyleID="s28"><Data ss:Type="String">New customers</Data></Cell>
- </Row>-->
- <Row>
- <Cell><Data ss:Type="String">Title</Data></Cell>
- <Cell><Data ss:Type="String">First name</Data></Cell>
- <Cell><Data ss:Type="String">Surname</Data></Cell>
- <Cell><Data ss:Type="String">Billing company</Data></Cell>
- <Cell><Data ss:Type="String">Billing phone</Data></Cell>
- <Cell><Data ss:Type="String">Billing fax</Data></Cell>
- <Cell><Data ss:Type="String">Billing address</Data></Cell>
- <Cell><Data ss:Type="String">Billing city</Data></Cell>
- <Cell><Data ss:Type="String">Billing state</Data></Cell>
- <Cell><Data ss:Type="String">Billing country</Data></Cell>
- <Cell><Data ss:Type="String">Billing zipcode</Data></Cell>
- <Cell><Data ss:Type="String">Shipping company</Data></Cell>
- <Cell><Data ss:Type="String">Shipping phone</Data></Cell>
- <Cell><Data ss:Type="String">Shipping fax</Data></Cell>
- <Cell><Data ss:Type="String">Shipping address</Data></Cell>
- <Cell><Data ss:Type="String">Shipping city</Data></Cell>
- <Cell><Data ss:Type="String">Shipping state</Data></Cell>
- <Cell><Data ss:Type="String">Shipping country</Data></Cell>
- <Cell><Data ss:Type="String">Shipping zipcode</Data></Cell>
- <Cell><Data ss:Type="String">Contact mail</Data></Cell>
- <Cell><Data ss:Type="String">Membership</Data></Cell>
- <Cell><Data ss:Type="String">Membership expiry</Data></Cell>
- <Cell><Data ss:Type="String">Vehicle regisration number</Data></Cell>
- <Cell><Data ss:Type="String">Contact phone number</Data></Cell>
- </Row>
- <Row FOREACH="customers,c">
- <Cell><Data ss:Type="String">{c.billing_title}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_firstname:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_lastname:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_company:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_phone:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_fax:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_address:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_city:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billingState.state:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billingCountry.country:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.billing_zipcode:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shipping_company:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shipping_phone:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shipping_fax:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shipping_address:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shipping_city:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shippingState.state:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shippingCountry.country:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.shipping_zipcode:t}</Data></Cell>
- <Cell><Data ss:Type="String">{c.login}</Data></Cell>
- <Cell><Data ss:Type="String">{c.pending_membership}</Data></Cell>
- <Cell><Data ss:Type="String">{time_format(c.membership_exp_date)}</Data></Cell>
- <Cell><Data ss:Type="String">{foreach:c.vehicles,v} {v.vehicle_registration_number} {end:}</Data></Cell>
- <Cell><Data ss:Type="String">{foreach:c.vehicles,v} {v.contact_phone_number} {end:}</Data></Cell>
- </Row>
- </Table>
- <WorksheetOptions xmlns="urn:schemas-microsoft-com:office:excel">
- <PageSetup>
- <PageMargins x:Bottom="0.984251969" x:Left="0.78740157499999996"
- x:Right="0.78740157499999996" x:Top="0.984251969"/>
- </PageSetup>
- <Print>
- <ValidPrinterInfo/>
- <PaperSizeIndex>9</PaperSizeIndex>
- <HorizontalResolution>600</HorizontalResolution>
- <VerticalResolution>600</VerticalResolution>
- </Print>
- <Panes>
- <Pane>
- <Number>3</Number>
- <ActiveRow>1</ActiveRow>
- <ActiveCol>1</ActiveCol>
- </Pane>
- </Panes>
- <ProtectObjects>False</ProtectObjects>
- <ProtectScenarios>False</ProtectScenarios>
- </WorksheetOptions>
- </Worksheet>
- </Workbook>