p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   C# (http://p2p.wrox.com/forumdisplay.php?f=22)
-   -   Collections in C#? (http://p2p.wrox.com/showthread.php?t=32571)

shenku August 17th, 2005 04:46 AM

Collections in C#?
 
Hi all

I am currently moving over from vb.net and have a simple code question. In vb.net you use collections as if they were a datatype something like...

Code:


        Private Function LoadCollection() As Collection
            Dim colPrivCol As New Collection
            colPrivCol.Add(oIPStory, oIPStory.Key)

but in C# I cant get a reference in the same way? I cant create a collection at all? Do I have to use ArrayLists?

thanks for your help.



shenku August 17th, 2005 06:16 AM

Sorry Im an idiot figured it out...

Essentially its true I was using collections like that BUT it was referencing the microsoft.visualbasic namespace which has a collection class.

Im using a hashtable instead...


All times are GMT -4. The time now is 07:19 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.