Tom,
it sounds like you are reusing the fileprops that you said: fileprops
= New TheNewFiles
If so, you need to call this for each new TheNewFiles you want
If you just call it once, you will store the same ref in each of the
NewFiles() aray elements
Lou
On Jul 30, 2009, at 10:32 PM, Tom Russell wrote:
I am doing something dumb and cannot see it.
Here's what I have:
A class called "TheNewFiles".
Then I have a global property called "NewFiles() as TheNewFiles"
Then in a thread I have this:
dim fileprops As TheNewFiles
fileprops = New TheNewFiles
Then farther in my code I have this:
fileprops.CRC = somedata
fileprops.MyID = somedata
fileprops.Path = somedata
fileprops.name = somedata
fileprops.f =somedata
NewFiles.Append fileprops
Basically I am just loading file names and the paths and some other
calculated data into the fileprops structure.
My problem is that I can see when I debug my code that the somedata
values are changing and all, however when the appending of the
NewFiles happens, it keeps adding the same item Im appending. I
essentially get a NewFiles array that is the same file data all the
way through it even though I could see the fileprops was different
each time I went to append it.
Any ideas on why this is happening and not doing what should be
pretty straight forward?
Thanks,
Tom
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>
|