我开始 看源代码,哦,跳出一个对话框是很简单的事请呵,比自己手动去写,简单多了
当我自己写的时候,却发现老说该东西没被声明,回头仔细看了一下,才知道,需要先加控件,那么,这个就真的简单了。
form上放一个lbl,2个btn,一个改变颜色,一个改变字体
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
ColorDialog1.ShowDialog()
Label1.ForeColor = ColorDialog1.Color
End Sub
Private Sub Button2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button2.Click
FontDialog1.ShowDialog()
Label1.Font = FontDialog1.Font
End Sub
浙公网安备 33010602011771号