Thread: collection obj
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
cate cate is offline
external usenet poster
 
Posts: 93
Default collection obj

I'm having some trouble with the collection obj. My first time out.
I seem can't test it.
(placing strings into what I would call a hash/dictionary. Am I doing
that?)

Dim usedFields As Collection
Set usedFields = New Collection

usedFields.Add("string); ' doesn't die

Later, I want to know if an item exists

if usedFields.Item("string")
if exists.usedFields ...
if usedFields.Item("string") < ""
if usedFields.Item("string") < 0

All get me the yellow bug line. How do test for exists?

Help. Thank you.