| | |
Sending variables from form to another
![]() |
•
•
Join Date: Jul 2008
Posts: 88
Reputation:
Solved Threads: 11
hi
in form1 -button click event write it as
and in 2nd form
it wil work.
if its working mark as PROBLEM SOLVED
in form1 -button click event write it as
•
•
•
•
Dim frm2 As New Form2(DateTime.Now, "hai")
frm2.Show()
•
•
•
•
Private dt1 As DateTime
Private str As String
Public Sub New(ByVal dt2 As DateTime, ByVal strname As String)
InitializeComponent()
dt1 = dt2
'str = strname;
textBox1.Text = strname
End Sub
if its working mark as PROBLEM SOLVED
•
•
Join Date: Oct 2008
Posts: 4
Reputation:
Solved Threads: 0
Hi There,
For your problem you can do the following::
In Form1 do::
public shared variable1 as datetime
'get the value from any event as per your program
Form2.date1=variable1
' then in the second form declare variable as
public shared date1 as datetime=Form1.variable
hope that this will help you.
Himanshu
For your problem you can do the following::
In Form1 do::
public shared variable1 as datetime
'get the value from any event as per your program
Form2.date1=variable1
' then in the second form declare variable as
public shared date1 as datetime=Form1.variable
hope that this will help you.
Himanshu
![]() |
Similar Threads
- sending variables in the URL (PHP)
- Web Order - Checkbox Values - sending via php mail (PHP)
- Sending a form via sendmail (PHP)
- Can a text link pass php variables? (PHP)
- 'Lock Down' a form (PHP)
- Help with asp form will not display contact information (ASP)
- Sending form email (PHP)
Other Threads in the VB.NET Forum
- Previous Thread: Saving data from datagridview to Access
- Next Thread: Problem in clearing old data from datagrid iew in VB.Net
Views: 1628 | Replies: 2
| Thread Tools | Search this Thread |
Tag cloud for VB.NET
.net .net2008 2005 2008 access account ado.net application array arrays basic bindingsource browser c# center checkbox client code combobox connection control convert crystal crystalreport data database datagrid datagridview dataset datatable date datetimepicker design designer dissertation dissertations error excel file firewall form gridview image images insert listview login loops mobile ms msaccess net objects openxml path port print printing problem read save search security serial server settings shutdown sms socket sorting sql statement studio syntax tagging tags textbox time timer type update upload user validation values vb vb.net vb2008 view visual visual-studio visualbasic visualstudio2008 vs2008 web webbrowser windows winforms wpf xml





