Substracting time values in Excel XML -
I am trying to subtract twice and get value in hours.
Obstacles:
- It appears that I need to specify a complete date, that I can not just use one time?
- In the second example, if I use a full date (i.e., 2014-08-22, tit 08: 30: 00), then in Excel, I look at the cell instead of the date of "41875.35"
This is my current markup:
& lt ;? XML version = "1.0"? & Gt; & Lt; Ss: workbook xmlns: ss = "vase: schema-microsoft-com: office: spreadsheet" & gt; & Lt; Ss: worksheet ss: name = "sheet 1" & gt; & Lt; SS: Table & gt; & Lt; Ss: line & gt; & Lt; SS: Cell & gt; & Lt; Ss: data ss: type = "date time" & gt; 08: 30: 00 & lt; / Ss: Data & gt; & Lt; / SS: Cell & gt; & Lt; / Ss: row & gt; & Lt; Ss: line & gt; & Lt; SS: Cell & gt; & Lt; Ss: data ss: type = "date time" & gt; 17: 30: 00 & lt; / Ss: Data & gt; & Lt; / SS: Cell & gt; & Lt; / Ss: row & gt; & Lt; Ss: line & gt; & Lt; Ss: cell ss: formula = "= int (r [-1] c-r [-2] c) * 24)" & gt; & Lt; / S: Cell & gt; & Lt; / Ss: row & gt; & Lt; / SS: Table & gt; & Lt; / Ss: worksheet & gt; & Lt; / SS: Workbook & gt; I get errors: XML error in table cause: bad value FILE: C: \ timediff.xml.xls GROUP: cell Tags: Data rate: 08:30:00 XML error in reference to table: bad value FILE: C: \ timediff.xml.xls GROUP: cell TAG: data VALUE: 17:30:00
< P> Update # 1 Newest Cut:
& lt ;? XML version = "1.0"? & Gt; & Lt; Ss: workbook xmlns: ss = "vase: schema-microsoft-com: office: spreadsheet" & gt; & Lt; Ss: worksheet ss: name = "sheet 1" & gt; & Lt; SS: Table & gt; & Lt; Ss: line & gt; & Lt; SS: Cell & gt; & Lt; Ss: data ss: type = "string" & gt; 08:30 & lt; / Ss: Data & gt; & Lt; / SS: Cell & gt; & Lt; / Ss: row & gt; & Lt; Ss: line & gt; & Lt; SS: Cell & gt; & Lt; Ss: data ss: type = "string" & gt; 17: 30 & lt; / Ss: Data & gt; & Lt; / SS: Cell & gt; & Lt; / Ss: row & gt; & Lt; Ss: line & gt; & Lt; Ss: cell ss: formula = "= round ((timeview (r [-1] c) - timevalue (r [-2] c) * 24, 1)" & gt; & lt; / ss: cell & gt; & Lt; / ss: line & gt; & lt; / ss: table & gt; & lt; / ss: worksheet & gt; & lt; / ss: workbook & gt;
The problem persists that, once in Excel, changing the 08:30 to 08:15 formula will give an error signal: #VALUE !.
ss: formula = "= round ((r [-1] CR [-2] c) * 24) - 0.5, 3)
Comments
Post a Comment