Click here to Skip to main content
15,914,419 members
Home / Discussions / C#
   

C#

 
AnswerRe: list in c# Pin
Christian Graus1-May-07 2:10
protectorChristian Graus1-May-07 2:10 
GeneralRe: list in c# Pin
lavy28831-May-07 2:47
lavy28831-May-07 2:47 
GeneralRe: list in c# Pin
Christian Graus1-May-07 10:35
protectorChristian Graus1-May-07 10:35 
QuestionClass inside namespace Pin
Rick van Woudenberg1-May-07 0:59
Rick van Woudenberg1-May-07 0:59 
AnswerRe: Class inside namespace Pin
PandemoniumPasha1-May-07 1:19
PandemoniumPasha1-May-07 1:19 
AnswerRe: Class inside namespace Pin
Stefan Troschuetz1-May-07 1:19
Stefan Troschuetz1-May-07 1:19 
GeneralRe: Class inside namespace Pin
Rick van Woudenberg1-May-07 1:32
Rick van Woudenberg1-May-07 1:32 
GeneralRe: Class inside namespace Pin
Stefan Troschuetz1-May-07 1:41
Stefan Troschuetz1-May-07 1:41 
GeneralRe: Class inside namespace Pin
RSArockiam1-May-07 1:42
RSArockiam1-May-07 1:42 
GeneralRe: Class inside namespace Pin
Rick van Woudenberg1-May-07 2:28
Rick van Woudenberg1-May-07 2:28 
GeneralRe: Class inside namespace Pin
RSArockiam1-May-07 2:32
RSArockiam1-May-07 2:32 
QuestionConvert a list element Pin
Anka_Ame1-May-07 0:36
Anka_Ame1-May-07 0:36 
AnswerRe: Convert a list element Pin
Pete O'Hanlon1-May-07 1:11
mvePete O'Hanlon1-May-07 1:11 
QuestionRe: Convert a list element Pin
DavidNohejl1-May-07 4:25
DavidNohejl1-May-07 4:25 
AnswerRe: Convert a list element Pin
Pete O'Hanlon1-May-07 5:17
mvePete O'Hanlon1-May-07 5:17 
GeneralRe: Convert a list element Pin
DavidNohejl1-May-07 8:14
DavidNohejl1-May-07 8:14 
GeneralRe: Convert a list element Pin
PIEBALDconsult3-May-07 9:02
mvePIEBALDconsult3-May-07 9:02 
QuestionReflection: How to locate/load a specific NameSpace inside an Assembly? Pin
Dominic Pettifer1-May-07 0:34
Dominic Pettifer1-May-07 0:34 
Hi,

I'm trying to find all classes that implement a specific abstract base class inside an Assembly, so far I have got the following...

Assembly assm = Assembly.GetExecutingAssembly();<br />
<br />
foreach (Type type in assm.GetTypes())<br />
{<br />
   if (type.IsSubclassOf(typeof(MyAbstractClass)))<br />
   {<br />
      Response.Write(type.ToString() + "<br />");<br />
   }<br />
}


...and this seems to work OK. However, my assembly is already fairly large and may grow, and as far as I can tell this code iterates through all types in the assembly, which I feel is inefficient.

I know all my derived classes will sit inside the same namespace, so was wondering if there's a way to iterate through all types inside a particular namespace only, instead of the entire assembly?

Cheers!

Dominic Pettifer

Blog: www.dominicpettifer.co.uk

QuestionC#, Interfaces and Interop Pin
Rhys Gravell1-May-07 0:13
professionalRhys Gravell1-May-07 0:13 
Questiondistinct values in dataset Pin
arkiboys30-Apr-07 23:30
arkiboys30-Apr-07 23:30 
AnswerRe: distinct values in dataset Pin
_mubashir1-May-07 0:12
_mubashir1-May-07 0:12 
QuestionCheck Windows username and password using C#.Net 2003 Pin
Dotnetkanna30-Apr-07 21:30
Dotnetkanna30-Apr-07 21:30 
AnswerRe: Check Windows username and password using C#.Net 2003 Pin
Christian Graus30-Apr-07 22:25
protectorChristian Graus30-Apr-07 22:25 
GeneralRe: Check Windows username and password using C#.Net 2003 Pin
Colin Angus Mackay30-Apr-07 22:30
Colin Angus Mackay30-Apr-07 22:30 
GeneralRe: Check Windows username and password using C#.Net 2003 Pin
Dotnetkanna30-Apr-07 23:40
Dotnetkanna30-Apr-07 23:40 

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.