Click to See Complete Forum and Search --> : always same font displayed regardless of choice


diprima
February 13th, 2000, 08:45 PM
I am writing a program (VB 5) which uses the common dialog box .ShowFont.
However no matter which font I choose, the font displayed is always Times New Roman, even if I only change the size or bold.
Using .flag for both.
What is happening?

Please Spend a minute to help me with this one.
Regards
Ivan

Lothar Haensler
February 14th, 2000, 02:23 AM
after displaying the font selection dialog you have to set the font properties of the relevant controls:

c.Flags = cdlCFScalableOnly Or cdlCFANSIOnly Or cdlCFNoFaceSel Or cdlCFNoVectorFonts Or cdlCFScreenFonts
c.ShowFont
Label1.Font.Bold = c.FontBold




only by Label1.Font.Bold = c.FontBold will the chosen font properties be assigned to the font properties of the control of your choice.

February 15th, 2000, 09:19 PM
Sorry if I didn't make myself clear, but size and bold work fine, it is only the fontname that seems to accept Times New Roman only.

Thank you again for your time.
ivan