Skip to content

Commit

Permalink
Merge pull request #573 from onizet/master
Browse files Browse the repository at this point in the history
Upgrade HtmlToOpenXml to v3
  • Loading branch information
xl-wenqiang authored Oct 28, 2024
2 parents 10fa4f1 + 4b79dd3 commit 422ddf2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="HtmlToOpenXml.dll" Version="2.0.3" />
<PackageReference Include="HtmlToOpenXml.dll" Version="3.1.0" />
</ItemGroup>

<ItemGroup>
Expand Down
8 changes: 4 additions & 4 deletions src/Magicodes.ExporterAndImporter.Word/WordExporter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public async Task<ExportFileInfo> ExportListByTemplate<T>(string fileName, IColl
}

var converter = new HtmlConverter(mainPart);
converter.ParseHtml(htmlString);
await converter.ParseHtml(htmlString);

mainPart.Document.Save();
}
Expand Down Expand Up @@ -147,7 +147,7 @@ public async Task<byte[]> ExportBytesByTemplate<T>(T data, string template) wher
}

var converter = new HtmlConverter(mainPart);
converter.ParseHtml(htmlString);
await converter.ParseHtml(htmlString);

mainPart.Document.Save();

Expand Down Expand Up @@ -185,7 +185,7 @@ public async Task<byte[]> ExportBytesByTemplate(object data, string template, Ty
}

var converter = new HtmlConverter(mainPart);
converter.ParseHtml(htmlString);
await converter.ParseHtml(htmlString);

mainPart.Document.Save();

Expand Down Expand Up @@ -232,7 +232,7 @@ public async Task<byte[]> ExportListBytesByTemplate<T>(ICollection<T> data, stri
}

var converter = new HtmlConverter(mainPart);
converter.ParseHtml(htmlString);
await converter.ParseHtml(htmlString);

mainPart.Document.Save();

Expand Down

0 comments on commit 422ddf2

Please sign in to comment.