Xbasic
Office::ExcelDocumentAddFont Method
Syntax
.AddFont as Office::Font ([InitialFont as Office::Font])
Arguments
- InitialFontOffice::Font
An existing Office::Font object. The values in the font object will be copied to the new Office::Font object.
Returns
- resultOffice::Font
Returns an Office::Font object representing the new font added to the spreadsheet.
Description
Create a new font and add it to the document. You can pass an existing font to copy its values into the new one.
Example
dim Doc as Office::ExcelDocument dim Font as Office::Font Font = Doc.AddFont() Font.Color = Office::Color::DarkBlue Font.Name= "Tahoma" Font.Size = 14 Font.Bold = .t.
See Also