EmbedFontInDocx Method (GdPictureDocumentUtilities)
This method embeds a font in a .docx file.
public static GdPictureStatus EmbedFontInDocx(
string ,
string ,
string ,
string ,
bool ,
bool
)
public function EmbedFontInDocx(
: String;
: String;
: String;
: String;
: Boolean;
: Boolean
): GdPictureStatus; static;
public static function EmbedFontInDocx(
: String,
: String,
: String,
: String,
: boolean,
: boolean
) : GdPictureStatus;
public: static GdPictureStatus EmbedFontInDocx(
string* ,
string* ,
string* ,
string* ,
bool ,
bool
)
public:
static GdPictureStatus EmbedFontInDocx(
String^ ,
String^ ,
String^ ,
String^ ,
bool ,
bool
)
'Declaration
Public Shared Function EmbedFontInDocx( _
ByVal As String, _
ByVal As String, _
ByVal As String, _
ByVal As String, _
ByVal As Boolean, _
ByVal As Boolean _
) As GdPictureStatus
Parameters
- inputWordFilePath
- The file name of the input document.
- outputWordFilePath
- The file name of the output document, could be the same as the file name of the input document
- fontName
- The name of the font to embed.
- fontFilePath
- The file name of the font to embed
- isBold
- True if the font file is used for a Bold or BoldItalic requested font.
- isItalic
- True if the font file is used for a Italic or BoldItalic requested font.
Return Value
A member of the GdPictureStatus enumeration.If the method has been successfully followed, then the return value is GdPictureStatus.OK.
GdPictureDocumentUtilities.EmbedFontInDocx(@"input_docx_missing_font.docx", @"output_docx_embedd_font.docx", @"FreeSans", @"input_font_FreeSansBoldOblique.otf", true, true)
GdPictureDocumentUtilities.EmbedFontInDocx(@"input_docx_missing_font.docx", @"output_docx_embedd_font.docx", @"FreeSans", @"input_font_FreeSansBoldOblique.otf", true, true);