J Jared Crystal Dec 14, 2007 #1 I am using NET20 and need to determine if font is installed on users machine? TIA
M Matt Lacey Dec 14, 2007 #2 I am using NET20 and need to determine if font is installed on users machine? TIA Click to expand... This should do the trick: using System.Drawing.Text; public bool fontIsInstalled(string fontName) { bool result = false; InstalledFontCollection installedFontCollection = new InstalledFontCollection(); foreach (FontFamily family in installedFontCollection.Families) { if (family.Name == fontName) { result = true; break; } } return result; }
I am using NET20 and need to determine if font is installed on users machine? TIA Click to expand... This should do the trick: using System.Drawing.Text; public bool fontIsInstalled(string fontName) { bool result = false; InstalledFontCollection installedFontCollection = new InstalledFontCollection(); foreach (FontFamily family in installedFontCollection.Families) { if (family.Name == fontName) { result = true; break; } } return result; }