Click here to Skip to main content
15,899,124 members
Home / Discussions / C#
   

C#

 
JokeRe: Problem with loading tiff-picture to Visual C# Project! Pin
The Cake of Deceit28-Aug-08 12:46
The Cake of Deceit28-Aug-08 12:46 
GeneralRe: Problem with loading tiff-picture to Visual C# Project! Pin
bugor7728-Aug-08 21:03
bugor7728-Aug-08 21:03 
GeneralRe: Problem with loading tiff-picture to Visual C# Project! Pin
The Cake of Deceit29-Aug-08 3:36
The Cake of Deceit29-Aug-08 3:36 
QuestionRetrieving Oracle servers but cannot get host name Pin
Antony Lyell28-Aug-08 4:34
Antony Lyell28-Aug-08 4:34 
AnswerRe: Retrieving Oracle servers but cannot get host name Pin
Wendelius28-Aug-08 7:57
mentorWendelius28-Aug-08 7:57 
GeneralRe: Retrieving Oracle servers but cannot get host name Pin
Antony Lyell28-Aug-08 21:56
Antony Lyell28-Aug-08 21:56 
GeneralRe: Retrieving Oracle servers but cannot get host name Pin
Wendelius29-Aug-08 7:00
mentorWendelius29-Aug-08 7:00 
QuestionInheritance and constructors Pin
Dewald28-Aug-08 4:22
Dewald28-Aug-08 4:22 
Hi all, I'm having a hard time getting my head around this() and base(), hoping someone can help.

Let's say I have classB which inherits classA both have a constructor and an overloaded constructor.

class classA
{
   public classA()
   {
      //some code
   }
   public classA(int i)
   {
      //some code
   }
}

class classB
{
   public classB()
   {
      //some code
   }
   public classB(int i)
   {
      //some code
   }
}


How do I get the overloaded constructor of classB to first call the default constructor of classB and then the similar overloaded constructor of the base class, classA? I seem to be able to have it call either the default constructor of classB OR the overloaded constructor of classA by declaring the overloaded constructor of classB as
public classB(int i) : this()
or
public classB(int i) : base(i)

but how do I get it to call both?
AnswerRe: Inheritance and constructors Pin
netJP12L28-Aug-08 4:35
netJP12L28-Aug-08 4:35 
GeneralRe: Inheritance and constructors Pin
Dewald29-Aug-08 3:11
Dewald29-Aug-08 3:11 
AnswerRe: Inheritance and constructors Pin
Pete O'Hanlon28-Aug-08 4:36
mvePete O'Hanlon28-Aug-08 4:36 
GeneralRe: Inheritance and constructors Pin
N a v a n e e t h28-Aug-08 5:21
N a v a n e e t h28-Aug-08 5:21 
GeneralRe: Inheritance and constructors Pin
Dewald29-Aug-08 3:26
Dewald29-Aug-08 3:26 
AnswerRe: Inheritance and constructors Pin
Frank Horn28-Aug-08 4:39
Frank Horn28-Aug-08 4:39 
GeneralRe: Inheritance and constructors Pin
Dewald29-Aug-08 3:31
Dewald29-Aug-08 3:31 
AnswerRe: Inheritance and constructors Pin
laserbaronen28-Aug-08 4:42
laserbaronen28-Aug-08 4:42 
GeneralRe: Inheritance and constructors Pin
Dewald29-Aug-08 3:31
Dewald29-Aug-08 3:31 
Question[Message Deleted] Pin
hadad28-Aug-08 4:16
hadad28-Aug-08 4:16 
AnswerRe: BinnaryWriter Class Pin
led mike28-Aug-08 5:05
led mike28-Aug-08 5:05 
GeneralRe: BinnaryWriter Class Pin
Mark Salsbery28-Aug-08 6:29
Mark Salsbery28-Aug-08 6:29 
GeneralRe: BinnaryWriter Class Pin
led mike28-Aug-08 6:42
led mike28-Aug-08 6:42 
GeneralRe: BinnaryWriter Class Pin
lisan_al_ghaib28-Aug-08 22:10
lisan_al_ghaib28-Aug-08 22:10 
GeneralRe: BinnaryWriter Class Pin
Mark Salsbery29-Aug-08 5:18
Mark Salsbery29-Aug-08 5:18 
JokeRe: BinnaryWriter Class Pin
lisan_al_ghaib29-Aug-08 5:22
lisan_al_ghaib29-Aug-08 5:22 
GeneralRe: BinnaryWriter Class Pin
Pete O'Hanlon28-Aug-08 8:13
mvePete O'Hanlon28-Aug-08 8:13 

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.