Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

5. Insert the text into the document with Document.InsertTextAfter

Csharp
5
5
DOC.InsertTextAfter(value, true);

...

Congratulations, you have completed Hello World using WordApplication!

Final Code

Csharp
7
7
using SoftArtisans.OfficeWriter.WordWriter;
...
WordApplication WAPP = new WordApplication();

Document DOC = WAPP.Create();

string value = DataValueBox.Text.Trim();

DOC.InsertTextAfter(value, true);

WAPP.Save(DOC, Response, "Output.doc", false);

...