Click here to Skip to main content
15,912,329 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Searching word Pin
Dave Kreskowiak2-Oct-06 4:48
mveDave Kreskowiak2-Oct-06 4:48 
GeneralRe: Searching word Pin
Xmen Real 2-Oct-06 9:00
professional Xmen Real 2-Oct-06 9:00 
QuestionSYSTEM DIR. Pin
msleem30-Sep-06 13:42
msleem30-Sep-06 13:42 
AnswerRe: SYSTEM DIR. Pin
Dave Kreskowiak1-Oct-06 14:27
mveDave Kreskowiak1-Oct-06 14:27 
Questionreading data from a dataset [modified] Pin
jon-8030-Sep-06 7:51
professionaljon-8030-Sep-06 7:51 
AnswerRe: reading data from a dataset Pin
freefika30-Sep-06 9:53
freefika30-Sep-06 9:53 
QuestionForm1 And Form2 Pin
Xmen Real 30-Sep-06 7:27
professional Xmen Real 30-Sep-06 7:27 
AnswerRe: Form1 And Form2 Pin
Christian Graus30-Sep-06 11:44
protectorChristian Graus30-Sep-06 11:44 
xmen_xwk wrote:
Dim a As New Form1
a.TextBox1.Text = "111"


I'm at a loss as to why so many people do this. a is a NEW instance of Form1. It has nothing whatsoever to do with the instance of Form1 that already exists and is visible. a has the text 111, and the other instance keeps whatever text it had.

You need to set up a delegate between Form1 and Form2, so that Form2 can call a method in Form1 and pass through the value.

Also, you need to keep your controls private or protected. I guess you've come from VB6 ? VB.NET is an object oriented language, one of the things you should aim to achive in an OO language is to hide as many details of your class to clients as possible.



Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog

GeneralRe: Form1 And Form2 Pin
Xmen Real 30-Sep-06 16:51
professional Xmen Real 30-Sep-06 16:51 
GeneralRe: Form1 And Form2 Pin
darkelv30-Sep-06 19:50
darkelv30-Sep-06 19:50 
GeneralRe: Form1 And Form2 [modified] Pin
Xmen Real 30-Sep-06 22:58
professional Xmen Real 30-Sep-06 22:58 
GeneralRe: Form1 And Form2 Pin
Christian Graus1-Oct-06 9:34
protectorChristian Graus1-Oct-06 9:34 
GeneralRe: Form1 And Form2 Pin
Christian Graus1-Oct-06 9:42
protectorChristian Graus1-Oct-06 9:42 
GeneralRe: Form1 And Form2 Pin
Xmen Real 1-Oct-06 19:55
professional Xmen Real 1-Oct-06 19:55 
GeneralRe: Form1 And Form2 Pin
Christian Graus1-Oct-06 21:34
protectorChristian Graus1-Oct-06 21:34 
GeneralRe: Form1 And Form2 Pin
Xmen Real 1-Oct-06 21:55
professional Xmen Real 1-Oct-06 21:55 
GeneralRe: Form1 And Form2 Pin
Christian Graus1-Oct-06 22:05
protectorChristian Graus1-Oct-06 22:05 
GeneralRe: Form1 And Form2 Pin
Xmen Real 1-Oct-06 23:19
professional Xmen Real 1-Oct-06 23:19 
GeneralRe: Form1 And Form2 Pin
Christian Graus1-Oct-06 23:28
protectorChristian Graus1-Oct-06 23:28 
GeneralRe: Form1 And Form2 Pin
Xmen Real 2-Oct-06 4:34
professional Xmen Real 2-Oct-06 4:34 
GeneralRe: Form1 And Form2 Pin
Xmen Real 2-Oct-06 9:03
professional Xmen Real 2-Oct-06 9:03 
GeneralRe: Form1 And Form2 Pin
Christian Graus2-Oct-06 9:15
protectorChristian Graus2-Oct-06 9:15 
QuestionPublishing website and making it show [modified] Pin
§tring§urfer30-Sep-06 5:35
§tring§urfer30-Sep-06 5:35 
AnswerRe: Publishing website and making it show Pin
Christian Graus30-Sep-06 11:52
protectorChristian Graus30-Sep-06 11:52 
GeneralRe: Publishing website and making it show Pin
§tring§urfer30-Sep-06 13:32
§tring§urfer30-Sep-06 13:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.