The text of this article is not in this database — only its details are. Read it on the old site: Passing Data Between Forms
12 Comments
Join the conversation! Your thoughts help the community grow.
Sign in to leave a comment.
The text of this article is not in this database — only its details are. Read it on the old site: Passing Data Between Forms
Join the conversation! Your thoughts help the community grow.
Sign in to leave a comment.
rick fergusonPosted Aug 1, 2012, 7:20 PM
i cant get any of them to work, i get 2 err msgs on the first form from the first example (the easiest by far) Error 1 Identifier expected. pass data try 1 Error 2 Identifier expected. pass data try 1 so what is it asking for?
RangaPosted Jul 5, 2011, 12:43 AM
u r the man !!!
Len FlynnPosted May 17, 2011, 10:23 PM
I am a C# developer currently being forced to update a VB app. I have a series of forms that can call an advanced search form (ASF) which must be able to cause the calling form to show the record that corresponds to that selected in the ASF while staying open. Your solution for using delegates was so simple that I was easily able to adapt it to suit my needs.
Arno PretoriusPosted Mar 16, 2011, 5:51 AM
The passing of data between forms was great and helped a lot. Can you please give an example of the following The display in form 2 must change in the same window when you change the text in form 1 and click the send button. So there must not pop up a new window just refresh or update the existing window.
steve hatcherPosted Sep 26, 2010, 10:00 AM
your example works great for 1 textbox and 1 label, but what about 2 textboxs and 2 labels on separate forms. would you please show an example on how that works. Thanks Steve
Parkash KaurPosted Dec 19, 2009, 1:35 AM
Can data pass into HTML format from sql database table in vbform?
Steve StacelPosted Aug 17, 2009, 10:51 AM
Hello, I thought the article you wrote regarding passing data between forms was excellent. I was attempting to use method 2 (Objects) when I received the following error: Error 1 'textBox1' is already declared as 'Friend WithEvents TextBox1 As System.Windows.Forms.TextBox' in this class. C:\Users\Steve\Documents\Visual Studio 2008\Projects\Passing Data Between Forms-Objects\Passing Data Between Forms-Objects\Form1.vb 3 23 Passing Data Between Forms-Objects. I am not sure how to correct this error. I coded the app exactly as you suggested. Thanks Steve
Lloyd McElaneyPosted Feb 13, 2008, 8:03 PM
The Simplest Approach. Step 1: Enter text in Form1’s TextBox1. Invoke the Form2 window by calling the Form2's show method in Form1's button click event handler. Private Sub btnSend_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSend.Click Form2.Show() End Sub Step 2: In Form2's Load method access Form1's TextBox1 and assign its Text to Form2’s Label1's Text. Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Label1.Text = Form1.TextBox1.Text End Sub
Mioara MitreaPosted Nov 22, 2007, 2:37 AM
It's quite a long time since I looked for an elegante way to transmit parameters between forms. So, now I found four ways ! Thank you .
Ashok kumarPosted Dec 27, 2006, 7:03 AM
sir i m a ug student studying .net in niit i m verymuch thankful for you for presenting this article i had this doubt but nobody could clear it on accidently viewing this page i came to know that we can gain many about .net from this site atlast i got the correct answer from you thro' this article thankyou verymuch sir