Click here to Skip to main content
15,919,434 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Class versus Form sharing Pin
cstrader23223-Dec-07 7:28
cstrader23223-Dec-07 7:28 
GeneralRe: Class versus Form sharing Pin
Dave Kreskowiak23-Dec-07 7:42
mveDave Kreskowiak23-Dec-07 7:42 
GeneralRe: Class versus Form sharing Pin
nlarson1123-Dec-07 9:21
nlarson1123-Dec-07 9:21 
GeneralRe: Class versus Form sharing Pin
Dave Kreskowiak23-Dec-07 7:43
mveDave Kreskowiak23-Dec-07 7:43 
GeneralRe: Class versus Form sharing Pin
cstrader23223-Dec-07 8:04
cstrader23223-Dec-07 8:04 
GeneralRe: Class versus Form sharing Pin
nlarson1123-Dec-07 9:23
nlarson1123-Dec-07 9:23 
GeneralRe: Class versus Form sharing Pin
cstrader23223-Dec-07 9:37
cstrader23223-Dec-07 9:37 
GeneralRe: Class versus Form sharing Pin
Dave Kreskowiak23-Dec-07 10:15
mveDave Kreskowiak23-Dec-07 10:15 
cstrader232 wrote:
then my test function in my code didn't need to be instantiated.


Yes, it does. A Form is just another class. There's nothing special about it that automatically makes its methods Shared.

The error you got has nothing to do with the class you made that inherited from Form. The code you wrote never made it to the line that uses the TestClass2.Test method. It bmbed out on the line before it.


A guide to posting questions on CodeProject[^]



Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic
     2006, 2007




GeneralRe: Class versus Form sharing Pin
cstrader23223-Dec-07 10:36
cstrader23223-Dec-07 10:36 
GeneralRe: Class versus Form sharing Pin
Dave Kreskowiak23-Dec-07 11:03
mveDave Kreskowiak23-Dec-07 11:03 
GeneralRe: Class versus Form sharing Pin
cstrader23223-Dec-07 11:30
cstrader23223-Dec-07 11:30 
GeneralRe: Class versus Form sharing Pin
darkelv23-Dec-07 13:08
darkelv23-Dec-07 13:08 
GeneralRe: Class versus Form sharing Pin
Dave Kreskowiak23-Dec-07 15:31
mveDave Kreskowiak23-Dec-07 15:31 
Generaldocumentdownload2 Pin
balakpn22-Dec-07 19:28
balakpn22-Dec-07 19:28 
GeneralRe: documentdownload2 Pin
Dave Kreskowiak23-Dec-07 4:58
mveDave Kreskowiak23-Dec-07 4:58 
GeneralRe: documentdownload2 Pin
balakpn23-Dec-07 17:01
balakpn23-Dec-07 17:01 
GeneralRe: documentdownload2 Pin
Dave Kreskowiak23-Dec-07 17:33
mveDave Kreskowiak23-Dec-07 17:33 
GeneralRe: documentdownload2 Pin
balakpn23-Dec-07 19:24
balakpn23-Dec-07 19:24 
Generalimage change on mouse over Pin
Eli Nurman22-Dec-07 6:08
Eli Nurman22-Dec-07 6:08 
GeneralRe: image change on mouse over Pin
Christian Graus22-Dec-07 9:22
protectorChristian Graus22-Dec-07 9:22 
GeneralRe: image change on mouse over Pin
Eli Nurman22-Dec-07 10:20
Eli Nurman22-Dec-07 10:20 
GeneralRe: image change on mouse over Pin
Christian Graus22-Dec-07 10:51
protectorChristian Graus22-Dec-07 10:51 
GeneralRe: image change on mouse over Pin
Eli Nurman22-Dec-07 10:54
Eli Nurman22-Dec-07 10:54 
GeneralRe: image change on mouse over Pin
The ANZAC22-Dec-07 12:40
The ANZAC22-Dec-07 12:40 
GeneralRe: image change on mouse over Pin
Christian Graus22-Dec-07 16:29
protectorChristian Graus22-Dec-07 16:29 

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.