realbasic-nug
[Top] [All Lists]

Re: Help please - "Moving files"

To: REALbasic NUG <realbasic-nug@lists.realsoftware.com>
Subject: Re: Help please - "Moving files"
From: Charles Yeomans <charles@declareSub.com>
Date: Thu, 12 Jun 2008 17:27:07 -0400
Authentication-results: mx.google.com; spf=neutral (google.com: 74.124.194.228 is neither permitted nor denied by best guess record for domain of realbasic-nug-bounces@lists.realsoftware.com) smtp.mail=realbasic-nug-bounces@lists.realsoftware.com
Delivered-to: listarchive@realsoftware.com
In-reply-to: <448230.65552.qm@web65610.mail.ac4.yahoo.com>
References: <448230.65552.qm@web65610.mail.ac4.yahoo.com>
Reply-to: REALbasic NUG <realbasic-nug@lists.realsoftware.com>
Sender: realbasic-nug-bounces@lists.realsoftware.com
Try recreating the parent FolderItem. Often that will get you the updated information.

Charles Yeomans

On Jun 12, 2008, at 4:17 PM, Lennox Jacob wrote:

OK, I have moved some files from C C C and placed them in DDD and my app is not aware of that, so that is why f = nil.

So I can either handle the exception error by throwing up a msgbox like this msgbox "Some files were moved from their original location" +chr(13) + chr(13) +_ "Please close this app and reopen it to locate and manage those files"
Return

or

I can do something to locate and manage those files rather than closing and reopening the app, any suggestions/recommendations about what I can do?

Thanks.

Lennox


Lennox Jacob <lenpartico@yahoo.com> wrote: OK,
I added
If f = nil then msgbox "***f = Nil***"
and indeed f is nil, but why is that when I just transferred a few files from C C C to DDD ? and how can I fix that, something needs to be refreshed I would think.
Lennox

M Pulis  wrote: A NilObjectException is from an object being Nil.

The object is your variable "f".

Is f = Nil?

Gary


On Jun 12, 2008, at 11:51 AM, 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  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:


Search the archives:




_______________________________________________
Unsubscribe or switch delivery mode:


Search the archives:



_______________________________________________
Unsubscribe or switch delivery mode:


Search the archives:




_______________________________________________
Unsubscribe or switch delivery mode:


Search the archives:




_______________________________________________
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>


<Prev in Thread] Current Thread [Next in Thread>