Skip to content

Commit

Permalink
docs: Added using statement to document translation in README.md.
Browse files Browse the repository at this point in the history
  • Loading branch information
benelori committed Jul 30, 2024
1 parent 9c4bb60 commit 04c8ea7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,10 +180,11 @@ that case the input file name (or extension) is required, so the DeepL API can
determine the file type:
```c#
...
using outputFile = File.OpenWrite(outputDocumentPath);
await translator.TranslateDocumentAsync(
new MemoryStream(buffer),
"Input file.docx", // An extension like ".docx" is also sufficient
File.OpenWrite(outputDocumentPath),
outputFile,
"EN",
"DE",
new DocumentTranslateOptions { Formality = Formality.More });
Expand Down

0 comments on commit 04c8ea7

Please sign in to comment.