Skip to content

Instantly share code, notes, and snippets.

@bjoerntx
Created March 15, 2024 15:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bjoerntx/323fb8404b450d3c7710b61854f2d1cd to your computer and use it in GitHub Desktop.
Save bjoerntx/323fb8404b450d3c7710b61854f2d1cd to your computer and use it in GitHub Desktop.
mergeTemplate() {
TXTextControl.saveDocument(TXTextControl.StreamType.InternalUnicodeFormat, (document: any) => {
this.mailMergeData.template = document.data;
// send a post request to the server
this.http.post('/mailmerge/mergetemplate', this.mailMergeData).subscribe(
(result) => {
this.mailMergeData = result;
TXTextControl.loadDocument(
TXTextControl.StreamType.InternalUnicodeFormat,
this.mailMergeData.document);
}
);
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment