There is exactly one object reference in that line of code. Ergo, the
NilObjectException is almost certainly raised because f is nil. That
object reference is obtained by assignment from dir.TrueItem(i). That
means that dir.TrueItem(i) returned nil. This can certainly happen,
so you should check for and handle that possibility.
Charles Yeomans
On Jun 12, 2008, at 2:51 PM, Lennox Jacob wrote:
Hi Dennis,
It recognises the new files
I added msgbox "i = " + str(i) and it does give the correct number
of files.
The error comes here
if f.name.Left(12) = "New Appts - " then
but I cannot figure it out
Lennox.
Dennis Birch <dennisbirch@gmail.com> wrote: On Thu, Jun 12, 2008 at
10:43 AM, Lennox Jacob wrote:
So when I click the pushbutton, all the files are moved from Folder
DDD to Folder C C C
Now if I move back some or all of those files from C C C to DDD and
click the pushbutton again I get a NilObjectException error, how do
I fix that?
The first thing you should do is add a breakpoint to the beginning of
the method and step through it to see where you are getting the
nilobjectexception. Then you'll be able to ask a more pointed question
that somebody might be able to help you with, or perhaps you'll grok
the answer yourself.
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>
|