.NET Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgramming.NET Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old April 17th, 2004, 09:12 PM
sasco sasco is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 2 sasco User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
checking for class type

I was wondering if there was any way of checking for an
object's class type if its user defined.

Lets say for example, i have an arraylist called 'shopping bag',
which contains objects of the classes: toiletry, food, magazine,
etc, all user defined.

Now if i want to break up that arraylist into seperate arrays or
arraylists of class specific objects (eg. array of toiletries) how
would i go about checking which one of the classes each
object in the 'shopping bag' arraylist belongs to.

-Matt
noob extrordinaire

---------------------------------------
PS. I'm referring to the VB.net language.

Reply With Quote
  #2  
Old April 18th, 2004, 10:37 AM
cmgowcity cmgowcity is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 1 cmgowcity User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
string type = object.GetType();

Reply With Quote
  #3  
Old April 19th, 2004, 04:16 AM
sasco sasco is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 2 sasco User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Errrr.... im not sure i get it. Could you please elaborate a
little if it's not too much trouble for you.

-Matt

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgramming.NET Development > checking for class type


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT