On Jun 23, 2006, at 6:40 AM, Tehenne wrote:
Other tests :
pathPC : C:\Documents and Settings\Bibi\Bureau\Requis\Medias
\monChien.jpg
pathMac : Mac X:Users:tehenne:Desktop:ohmiNeries:intro.html
Test :
if getFolderItem(path)<>nil and getFolderItem(path).exists then
msgbox "OK"
else
msgbox "NO"
end
On a Mac (Mac OS X) :
- with the pathPC, the answer is OK ;o(((
- with the pathMac the answer is OK or NO as the file exists or not
On a PC (Windows) :
- with the pathMac or the pathPC, the answer is OK or NO as the
file exists or not
Regards,
if you change your code to
dim path as string
dim f as folderItem
path="C:\Documents and Settings\Bibi\Bureau\Requis\Medias
\monChien.jpg"
f= getFolderItem(path)
if f <> nil and f.exists then
msgbox "OK"
else
msgbox "NO"
end
and step through it you'll see what's going on
On OS X f is not nil and is probably NOT accessing the file you think
it is at all
The reason is that GetFolderItem does not know what kind of path you
are trying to use so it gives you a folderItem pointed to the wrong file
If you use this instead
f = getFolderItem(path,FolderItem.PathTypeAbsolute)
I'd expect things should be better ... but trying it in 2005r4
suggests this is not the case (at least not in the debugger)
I think this is a bug in GetFolderitem
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>