Click here to Skip to main content
16,007,126 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Class Pin
momooomooomomo15-Nov-06 19:03
momooomooomomo15-Nov-06 19:03 
QuestionWhy so hard to write to a textbox? Pin
cstrader23215-Nov-06 12:18
cstrader23215-Nov-06 12:18 
AnswerRe: Why so hard to write to a textbox? Pin
Christian Graus15-Nov-06 13:12
protectorChristian Graus15-Nov-06 13:12 
AnswerRe: Why so hard to write to a textbox? Pin
Yona Low15-Nov-06 13:15
Yona Low15-Nov-06 13:15 
GeneralRe: Why so hard to write to a textbox? Pin
cstrader23215-Nov-06 15:27
cstrader23215-Nov-06 15:27 
GeneralRe: Why so hard to write to a textbox? Pin
Yona Low16-Nov-06 3:48
Yona Low16-Nov-06 3:48 
GeneralRe: Why so hard to write to a textbox? Pin
cstrader23218-Nov-06 3:31
cstrader23218-Nov-06 3:31 
AnswerRe: Why so hard to write to a textbox? Pin
Yona Low19-Nov-06 8:07
Yona Low19-Nov-06 8:07 
When your calling the sub onLogon() it calls the WriteToLog() method on another Form1 Class, (its just a class as any other class) You need to somehow pass a reference to the original Form1 class that was created when your application started to the Application Class, and call WriteToLog() on that reference.

Code might look like this:

'Class Declaration
<br />
Public Class Application<br />
    Public frm As Form1 = Nothing<br />
<br />
    Public Sub onLogon()<br />
        If frm IsNot Nothing Then frm.WriteToLog("Hello from Application class")<br />
    End Sub<br />
End Class<br />


'From any sub or other thread:
<br />
Dim a as New Application<br />
a.frm = me<br />
a.onLogon<br />


I tested it and it worked in my test setup
Questionvb.net 2003 and Crystal Reports Pin
xtodazee15-Nov-06 10:39
xtodazee15-Nov-06 10:39 
QuestionSplit Binary Files Pin
flash.tato15-Nov-06 9:19
flash.tato15-Nov-06 9:19 
AnswerRe: Split Binary Files Pin
Christian Graus15-Nov-06 9:45
protectorChristian Graus15-Nov-06 9:45 
Questionfor quiz program Pin
bapu288915-Nov-06 9:04
bapu288915-Nov-06 9:04 
AnswerRe: for quiz program Pin
Christian Graus15-Nov-06 9:20
protectorChristian Graus15-Nov-06 9:20 
QuestionRe: for quiz program Pin
bapu288916-Nov-06 9:11
bapu288916-Nov-06 9:11 
AnswerRe: for quiz program Pin
Christian Graus16-Nov-06 9:18
protectorChristian Graus16-Nov-06 9:18 
QuestionRe: for quiz program Pin
bapu288916-Nov-06 9:26
bapu288916-Nov-06 9:26 
AnswerRe: for quiz program Pin
Christian Graus16-Nov-06 9:39
protectorChristian Graus16-Nov-06 9:39 
AnswerRe: for quiz program Pin
bapu288916-Nov-06 9:51
bapu288916-Nov-06 9:51 
QuestionDatagrid - Populate with SQL Select Statement Pin
Larry White15-Nov-06 7:53
Larry White15-Nov-06 7:53 
AnswerRe: Datagrid - Populate with SQL Select Statement Pin
Kevin Nicol15-Nov-06 8:53
Kevin Nicol15-Nov-06 8:53 
GeneralRe: Datagrid - Populate with SQL Select Statement Pin
Larry White15-Nov-06 10:12
Larry White15-Nov-06 10:12 
GeneralRe: Datagrid - Populate with SQL Select Statement Pin
Larry White15-Nov-06 10:36
Larry White15-Nov-06 10:36 
Questioncopy a file from a web folder Pin
CS_0115-Nov-06 7:46
CS_0115-Nov-06 7:46 
QuestionWeb service problem with VS.net 2005 and proxy server Pin
tjsharkfan15-Nov-06 7:40
tjsharkfan15-Nov-06 7:40 
Questionvisual studio .NET / required files Pin
7prince15-Nov-06 6:33
7prince15-Nov-06 6:33 

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.