You can either add a property to the form or add your own form constructor.
An example of the first method would look like this: (where Message is the name of the property)
frm.Message = "Some text"
An example of the second method will look like
Dim frm As New SampleForm ( "Some text" )
Your form code will look like
Public Class SampleForm Private someMessage As String Public Sub New(ByVal msg As String) InitializeComponent() If Not (String.IsNullOrEmpty(msg)) Then someMessage = msg End If End Sub Property Message() As String Get Return someMessage End Get Set(ByVal Value As String) someMessage = Value End Set End Property End Class
source share