Click here to Skip to main content
15,894,405 members
Home / Discussions / C#
   

C#

 
AnswerRe: Where to keep the public variables & Functions? VS2010 Pin
#realJSOP9-May-11 8:15
mve#realJSOP9-May-11 8:15 
GeneralRe: Where to keep the public variables & Functions? VS2010 Pin
SilimSayo9-May-11 11:38
SilimSayo9-May-11 11:38 
GeneralRe: Where to keep the public variables & Functions? VS2010 Pin
PIEBALDconsult9-May-11 14:14
mvePIEBALDconsult9-May-11 14:14 
GeneralRe: Where to keep the public variables & Functions? VS2010 Pin
SilimSayo11-May-11 6:30
SilimSayo11-May-11 6:30 
GeneralRe: Where to keep the public variables & Functions? VS2010 Pin
PIEBALDconsult11-May-11 14:31
mvePIEBALDconsult11-May-11 14:31 
AnswerRe: Where to keep the public variables & Functions? VS2010 Pin
Shameel9-May-11 18:10
professionalShameel9-May-11 18:10 
GeneralRe: Where to keep the public variables & Functions? VS2010 Pin
Paramu197310-May-11 0:12
Paramu197310-May-11 0:12 
QuestionSpace in a c# wordAddIn project Pin
Pierre besquent9-May-11 0:43
Pierre besquent9-May-11 0:43 
Questionkdtele disconnect problem Pin
mobasher8-May-11 23:22
mobasher8-May-11 23:22 
AnswerRe: kdtele disconnect problem Pin
Dave Kreskowiak9-May-11 1:23
mveDave Kreskowiak9-May-11 1:23 
Questionc# application hang plz help Pin
spider_vikas8-May-11 20:57
spider_vikas8-May-11 20:57 
AnswerRe: c# application hang plz help Pin
Łukasz Nowakowski8-May-11 21:41
Łukasz Nowakowski8-May-11 21:41 
GeneralWhich kind of connects can be captured by Win32_ServerConnection!! [modified] Pin
Member 46594858-May-11 17:39
Member 46594858-May-11 17:39 
AnswerRe: Unable to get connected users by Win32_ServerConnection!! Pin
OriginalGriff8-May-11 20:31
mveOriginalGriff8-May-11 20:31 
GeneralRe: Unable to get connected users by Win32_ServerConnection!! Pin
Member 46594858-May-11 21:08
Member 46594858-May-11 21:08 
AnswerRe: Unable to get connected users by Win32_ServerConnection!! Pin
OriginalGriff8-May-11 21:18
mveOriginalGriff8-May-11 21:18 
GeneralRe: Unable to get connected users by Win32_ServerConnection!! Pin
Member 46594858-May-11 21:22
Member 46594858-May-11 21:22 
AnswerRe: Unable to get connected users by Win32_ServerConnection!! Pin
OriginalGriff8-May-11 21:29
mveOriginalGriff8-May-11 21:29 
GeneralRe: Unable to get connected users by Win32_ServerConnection!! Pin
OriginalGriff8-May-11 21:20
mveOriginalGriff8-May-11 21:20 
GeneralRe: Unable to get connected users by Win32_ServerConnection!! Pin
Member 46594858-May-11 21:25
Member 46594858-May-11 21:25 
QuestionGeneric linked list Pin
frofrofrofro7-May-11 5:56
frofrofrofro7-May-11 5:56 
AnswerRe: Generic linked list Pin
Luc Pattyn7-May-11 7:00
sitebuilderLuc Pattyn7-May-11 7:00 
Are you asking about your own implementation of LinkedList? There is one available in .NET since 2.0

This would be an example of its use:
public class CPTest_LinkedList : CPTest {
	public override void Test(int arg) {
		LinkedList<Person> persons=new LinkedList<Person>();
		foreach(string s in new string[]{"jef", "jan", "jos"}) persons.AddLast(new Person(s));
		foreach(Person p in persons) log(p.Name);
		foreach(Person p in persons) if (p.ID==1) log("person 1 = "+p.Name);
	}

	public class Person {
		public string Name;
		public int ID;
		public static int count=0;

		public Person(string name) { Name=name; ID=count++; }
	}
}


which outputs:
18:57:36.439    CPTest.log-59                        jef
18:57:36.453    CPTest.log-59                        jan
18:57:36.467    CPTest.log-59                        jos
18:57:36.479    CPTest.log-59                        person 1 = jan


Its use is pretty easy as it implements ICollection. The one thing you can't do with such LinkedList is indexing, as in persons[1] which works fine in array-based collections such as List<T> itself. Indexing in LinkedList requires scanning the list one node at a time.

Smile | :)
Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum
Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.

modified on Saturday, May 7, 2011 2:46 PM

AnswerRe: Generic linked list Pin
PIEBALDconsult7-May-11 14:06
mvePIEBALDconsult7-May-11 14:06 
JokeRe: Generic linked list Pin
Peter_in_27807-May-11 19:48
professionalPeter_in_27807-May-11 19:48 
GeneralRe: Generic linked list Pin
Luc Pattyn8-May-11 23:51
sitebuilderLuc Pattyn8-May-11 23:51 

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.