Joe,


As I explain earlier, I save in a RealSQLDB the reference to 3 folderItem, using this code

app.DossierAppa = f.GetSaveInfo(f,0) //app.DossierAppa is a String Property
...

rec.Column("Appa_Folder") = EncodeBase64(DossierAppa)
etc...


When I start the app I need to check if the Folders are still in their respective place as stored in the DB.

I use the following code which works fine as long as one of the folder (ie. DossierApp in my example) is missing.

DossierAppa = DecodeBase64(rsPATH.Field("Appa_folder").Value)
        // msgbox DossierAppa
        dim ff As FolderItem
        ff = new FolderItem(DossierAppa)
        if ff = Nil then
                // Folder not found
                else
                // Folder found
        end if

The code returns the error message in : ff = new FolderItem(DossierAppa)

If the Folder is on the right place then, everything is smooth, therefore it let me think that the value stored in "DossierAppa" is correct.

Any idea?


Best Regards,


Youri



[EMAIL PROTECTED] wrote:
On Jan 16, 2007, at 16:52 UTC, Youri wrote:

I tried to test for DossierAppa <> "" but it passes the test
and chokes!

Then the path is not empty but nontheless an invalid format.  I'm
tuning in late here, so maybe that's why I don't understand why this is
a big deal.  If given an invalid format, an exception is exactly what
is supposed to happen.  Just use try/catch to catch it, display a nice
error message to the user, and go on to more interesting things.

Also note that if this isn't a user-entered path, but rather you're
trying to save and restore a FolderItem reference within your own code,
then you shouldn't be using paths at all.  Use GetSaveInfo, if you're
not already doing so.

HTH,
- Joe
_______________________________________________
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>

Reply via email to