>I have a section of code that loops through a view. Depending on certain conditions, I do a SCATTER of the current record to an object named oRecord and change any necessary property values so that I can insert a new record into the view from oRecord. Since I don't want to ruin the record pointer in the middle of the loop (or process the inserted records within the loop), I instantiated a collection object to hold all of the oRecord objects. My plan was to iterate through the collection after the main loop was done and insert records from the oRecord objects contained in the collection.
>
>Unfortunately, this doesn't work. For whatever reason, the insert creates a blank record in the view. Why would this happen? When I compare the object from the collection with the object that was created from the SCATTER, all of the properties are exactly the same. Yet, the insert doesn't work when the object is referenced from a collection.
>
>Any ideas on this or should I use a different approach?
Not sure why it didn't work this way, but you can create a temporary cursor for the insertion, this probably would be faster than collection.
You can also post some code, may be there is an error in the way you're doing it.
If it's not broken, fix it until it is.
My Blog