Click here to Skip to main content
15,902,189 members
Home / Discussions / Visual Basic
   

Visual Basic

 
Question[Message Deleted] Pin
oxela11-May-09 7:42
oxela11-May-09 7:42 
AnswerRe: how to connect the buissnes layer with other layers Pin
nlarson1111-May-09 9:31
nlarson1111-May-09 9:31 
AnswerRe: how to connect the buissnes layer with other layers Pin
Mycroft Holmes11-May-09 18:11
professionalMycroft Holmes11-May-09 18:11 
AnswerRe: how to connect the buissnes layer with other layers Pin
Dave Kreskowiak11-May-09 18:52
mveDave Kreskowiak11-May-09 18:52 
AnswerRe: how to connect the buissnes layer with other layers Pin
oxela14-May-09 7:18
oxela14-May-09 7:18 
Questiondatatable in VB.net Pin
Pankaj-codeproject11-May-09 6:36
Pankaj-codeproject11-May-09 6:36 
AnswerRe: datatable in VB.net Pin
Dave Kreskowiak11-May-09 6:50
mveDave Kreskowiak11-May-09 6:50 
Questionmybase.new Pin
sabr4911-May-09 6:18
sabr4911-May-09 6:18 
I am a bit of a newbie and don't understand something... When you have a base class with a parameterized constructor you need to call mybase.new on the derived classes to instantiate the base class because the base class is called first which got me thinking if that was always the case even when there is no explicit constructor in the base class. So after fooling with a simple example I discovered that indeed it it is true, because even a non paramaterized base is instantiated when the derived class is called. So for example :

Class Fruit

Sub New()
Console.WriteLine("hello, im a fruit")

End Sub
End Class
Class Apple : Inherits Fruit
Sub New()
Console.WriteLine("hi, im an apple")

End Sub

End Class

the console would output both. My question is why? I don't understand why the base class needs to be created at all? Isn't it enough for a derived class to be created that has all the methods and fields of the base without creating a separate object just for the base class or perhaps I don't understand what is really going on behind the scenes.

If someone could enlighten me I would appreciate it.

Thanks,

Steve
AnswerRe: mybase.new Pin
Luc Pattyn11-May-09 6:27
sitebuilderLuc Pattyn11-May-09 6:27 
Questionsmooth motion Pin
TheMrProgrammer11-May-09 6:11
TheMrProgrammer11-May-09 6:11 
AnswerRe: smooth motion Pin
Dave Kreskowiak11-May-09 6:48
mveDave Kreskowiak11-May-09 6:48 
GeneralRe: smooth motion Pin
TheMrProgrammer11-May-09 7:06
TheMrProgrammer11-May-09 7:06 
GeneralRe: smooth motion Pin
Luc Pattyn11-May-09 7:33
sitebuilderLuc Pattyn11-May-09 7:33 
Questionhow to view orginal address format in textbox Pin
JC.KaNNaN11-May-09 1:37
JC.KaNNaN11-May-09 1:37 
AnswerRe: how to view orginal address format in textbox Pin
dan!sh 11-May-09 1:54
professional dan!sh 11-May-09 1:54 
GeneralRe: how to view orginal address format in textbox Pin
JC.KaNNaN11-May-09 2:29
JC.KaNNaN11-May-09 2:29 
AnswerRe: how to view orginal address format in textbox Pin
riced11-May-09 6:01
riced11-May-09 6:01 
QuestionCompare Date Pin
vijay248210-May-09 23:59
vijay248210-May-09 23:59 
AnswerRe: Compare Date Pin
dan!sh 11-May-09 0:46
professional dan!sh 11-May-09 0:46 
GeneralRe: Compare Date Pin
vijay248211-May-09 1:08
vijay248211-May-09 1:08 
GeneralRe: Compare Date Pin
dan!sh 11-May-09 1:47
professional dan!sh 11-May-09 1:47 
GeneralRe: Compare Date Pin
vijay248211-May-09 1:48
vijay248211-May-09 1:48 
AnswerRe: Compare Date Pin
riced11-May-09 2:48
riced11-May-09 2:48 
QuestionControl not coming in designer. Pin
Pankaj-codeproject10-May-09 23:43
Pankaj-codeproject10-May-09 23:43 
AnswerRe: Control not coming in designer. Pin
N a v a n e e t h10-May-09 23:45
N a v a n e e t h10-May-09 23:45 

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.