程序代码:
=== 这个代码是字体的代码===
Private Sub ziti_Click(Index As Integer)
CommonDialog1.CancelError = True
CommonDialog1.Flags = cdlCFBoth Or cdlCFEffects
CommonDialog1.ShowFont
Text1.Font.Name = CommonDialog1.FontName
Text1.Font.Size = CommonDialog1.FontSize
Text1.Font.Bold = CommonDialog1.FontBold
Text1.Font.Italic = CommonDialog1.FontItalic
Text1.Font.Underline = CommonDialog1.FontUnderline
Text1.FontStrikethru = CommonDialog1.FontStrikethru
Text1.ForeColor = CommonDialog1.Color
Exit Sub
End Sub
====这个是字体的颜色的代码==
Private Sub yanse_Click(Index As Integer)
CommonDialog1.CancelError = True
CommonDialog1.Flags = cdlCCRGBInit
CommonDialog1.ShowColor
Text1.BackColor = CommonDialog1.Color
Exit Sub
End Sub