Click here to Skip to main content
15,905,420 members
Home / Discussions / C#
   

C#

 
GeneralRe: Variable of type Pin
jabbawok20-Apr-10 11:12
jabbawok20-Apr-10 11:12 
GeneralRe: Variable of type Pin
Luc Pattyn20-Apr-10 11:15
sitebuilderLuc Pattyn20-Apr-10 11:15 
GeneralRe: Variable of type Pin
jabbawok20-Apr-10 11:23
jabbawok20-Apr-10 11:23 
AnswerRe: Variable of type Pin
jabbawok20-Apr-10 12:56
jabbawok20-Apr-10 12:56 
AnswerRe: Variable of type Pin
AspDotNetDev20-Apr-10 13:04
protectorAspDotNetDev20-Apr-10 13:04 
GeneralRe: Variable of type Pin
jabbawok20-Apr-10 13:32
jabbawok20-Apr-10 13:32 
AnswerRe: Variable of type Pin
AspDotNetDev20-Apr-10 14:04
protectorAspDotNetDev20-Apr-10 14:04 
AnswerRe: Variable of type Pin
AspDotNetDev20-Apr-10 14:09
protectorAspDotNetDev20-Apr-10 14:09 
Also, this third overload will probably be more useful to you, since you are storing types in variables.

C#
// Example usage.
public void SomeMethod()
{
    //Animal a = Create<Animal, Dragon>(5);
    //Dragon d = Create<Dragon>(5);
    Animal a2 = CreateInstance<Animal>(typeof(Dragon), 5);
}

// This uses a type variable rather than generic parameter.
public TReturn CreateInstance<TReturn>(Type t, params object[] parameters)
{
    return (TReturn)Activator.CreateInstance(t, parameters);
}


QuestionwebBrowser controll and post Pin
Ziga120-Apr-10 9:21
Ziga120-Apr-10 9:21 
AnswerRe: webBrowser controll and post Pin
Ravi Bhavnani20-Apr-10 11:11
professionalRavi Bhavnani20-Apr-10 11:11 
GeneralRe: webBrowser controll and post Pin
Ziga120-Apr-10 21:32
Ziga120-Apr-10 21:32 
GeneralRe: webBrowser controll and post Pin
Ravi Bhavnani21-Apr-10 2:15
professionalRavi Bhavnani21-Apr-10 2:15 
QuestionImage Drawing Question Pin
eddieangel20-Apr-10 8:51
eddieangel20-Apr-10 8:51 
AnswerRe: Image Drawing Question Pin
Dr.Walt Fair, PE20-Apr-10 9:02
professionalDr.Walt Fair, PE20-Apr-10 9:02 
AnswerRe: Image Drawing Question Pin
Luc Pattyn20-Apr-10 9:22
sitebuilderLuc Pattyn20-Apr-10 9:22 
GeneralRe: Image Drawing Question Pin
eddieangel20-Apr-10 9:48
eddieangel20-Apr-10 9:48 
QuestionProblem IN use Of Application.DoEvents() [modified] Pin
shahramkeyboard20-Apr-10 8:26
shahramkeyboard20-Apr-10 8:26 
AnswerRe: Problem IN use Of Application.DoEvents() Pin
Luc Pattyn20-Apr-10 8:36
sitebuilderLuc Pattyn20-Apr-10 8:36 
AnswerRe: Problem IN use Of Application.DoEvents() Pin
Alan N20-Apr-10 8:54
Alan N20-Apr-10 8:54 
GeneralRe: Problem IN use Of Application.DoEvents() Pin
shahramkeyboard20-Apr-10 9:50
shahramkeyboard20-Apr-10 9:50 
GeneralRe: Problem IN use Of Application.DoEvents() Pin
Luc Pattyn20-Apr-10 10:47
sitebuilderLuc Pattyn20-Apr-10 10:47 
Questioncreating a schedule similar to sunbirt/outlook .... [modified] Pin
mrkeivan20-Apr-10 6:27
mrkeivan20-Apr-10 6:27 
AnswerRe: creating a schedule similar to sunbirt/outlook .... Pin
Gonzoox20-Apr-10 7:23
Gonzoox20-Apr-10 7:23 
GeneralRe: creating a schedule similar to sunbirt/outlook .... Pin
mrkeivan20-Apr-10 18:43
mrkeivan20-Apr-10 18:43 
AnswerRe: creating a schedule similar to sunbirt/outlook .... Pin
Anthony Mushrow20-Apr-10 10:20
professionalAnthony Mushrow20-Apr-10 10:20 

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.