Saturday, 28 January 2012

How to use advanced message box in vb.net?


How to use advanced message box in vb.net?
In this tutorial you can learn how to make advanced message box in vb.net?
Step1:
Open Microsoft visual studio
Step2:
Select the file new àwindows form applicationàrename it as advanced message box
Step3:
Drag and drop Button form tool box
Step4:
Write the below code on program window
Code:
Public Class form1


    Private SubButton1_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) HandlesButton1.Click
        If MessageBox.Show("if you under 16 click yes", "if you under 16 click yes", _ MessageBoxButtons.YesNo, MessageBoxIcon.Question) = Windows.Forms.DialogResult.Yes Then
            MessageBox.Show("don't see ")

        Else
            MessageBox.Show("you can see")
        End If

    End Sub
End Class

Output:

No comments:

Post a Comment