Hello, All!
Hi All,
I'm currently updating some program to make it use the VFS. The program uses
a .pdb file and I'd like to let the user place this file on the SD card. So
I'm trying to register a default directory on the SD card with a piece of
code like this:
***
Err err;
Char pathStr[50];
UInt16 bufLenP;
VFSSlotMountParamType slotParamP;
UInt32 slotIterator = expIteratorStart;
bufLenP = 50;
slotParamP.vfsMountParam.mountClass = VFSMountClass_SlotDriver;
err = ExpSlotEnumerate(&slotParamP.slotRefNum, &slotIterator);
err = ExpSlotLibFind(slotParamP.slotRefNum, &(slotParamP.slotLibRefNum));
err = VFSVolumeMount(NULL, NULL, (VFSAnyMountParamPtr)&slotParamP);
VFSGetDefaultDirectory (slotParamP.vfsMountParam.volRefNum, ".pdb",
pathStr, &bufLenP);
err = VFSUnregisterDefaultDirectory(".pdb", expMediaType_Any);
err = VFSRegisterDefaultDirectory(".pdb", expMediaType_Any, "/MyDir/");
***
When executing, 'err' variable is NULL after every function call.
But:
1. If I call VFSGetDefaultDirectory again, I do not get "/MyDir/", but an
empty string.
2. After that, the DmOpenDatabaseByTypeCreator function still does not find
the .pdb file in the /MyDir on the SD card.
What do I miss?
BTW, are there any docs somewhere on the net on using the VFS manager?
Thank you for your help.
Evgeny.
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/