Skip to content

Commit 37281b8

Browse files
feat: OpenXML.Excel.File.get_Cell ( Fixes #6 )
Handling text cells
1 parent 3dae7c1 commit 37281b8

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

Examples/Sample.pptx

-14.5 MB
Binary file not shown.
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,16 @@
11
$excelCells = [Ordered]@{
22

33
}
4+
$sharedStrings = $this.OpenXML.Parts['/xl/sharedStrings.xml'].Content
45
foreach ($worksheetRow in $this.content.worksheet.sheetdata.row) {
56
foreach ($worksheetColumn in $worksheetRow.c) {
6-
$excelCells[$worksheetColumn.r] = $worksheetColumn.v
7+
8+
$excelCells[$worksheetColumn.r] =
9+
if ($worksheetColumn.t -eq 's') {
10+
$this.OpenXML.SharedStrings[$worksheetColumn.v -as [int]]
11+
} else {
12+
$worksheetColumn.v
13+
}
714
}
815
}
916
$excelCells

0 commit comments

Comments
 (0)