Change the caption of Label1 and Label2 when click on Form

1. Create a new project

2. Add two table  from toolbox on the form.

3. Double click on Form to open code window and type the following code

Private Sub Form_Click()

Label1.Caption = “hello students”

Label2.Caption = “welcome”

End Sub

4. Press F5 to run






Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>