Simple question about changing a value of an object in a collection
Posted on 2006-05-05
I have this code
dim id as integer
dim name as string
private coll as new collection
pubic sub SetName (name as string, idKey as integer)
dim tmpB as b
tmpB = coll(idKey)
tmpB.name = name
Assuming that the collection already as a bunch of "b" structures in it and I want to change the name variable, the SetName function doesn't work. It pulls the correct struct out based on the id key but the name doesn't permenantly change. How do you make the data save back in the collection?
Or is there a better way to do this?