Frequently Asked Questions

Home | SourceForge Page | Version History | FAQ | Documentation | About Me

Q. How do I install this library?
As of version 1.15, installation of the conduit library is greatly simplified. As long as you have the Palm Desktop software installed on your system, you should be able to simple compile and install the source. When releasing a compiled conduit onto a client's system, it will be a good idea to follow the Palm Inc. recommended procedure of including a copy of userdata.dll in the same directory as your installed conduit. Just to be on the safe side, though, if a copy of Userdata.dll isn't found, the library will try to find the correct Palm DLL directory from the registry.

Q. Do I need to do anything when I release a conduit made with the library?
As just mentioned in the previous question, it is a good idea to include a copy of Userdata.dll in the same directory as the one in which you install your conduit, although it is not mandated, since a compiled conduit will automatically fall back on checking the registry for the DLL locations if it can't find the Userdata.dll file.

Previous versions of the library required the Palm DLLs to be in the system search path, or for the conduit to be installed in the same directory as them (normally c:\Palm). This is no longer the case.

Q. I tried changing the database attributes on an open database using the DbFlags property, but nothing changed? Why not?
Currently, the Palm Sync API doesn't have any way to change a database's attributes after it's created (at least, none that I know of). The DbFlags property is only used when first creating a database. As of version 1.12, setting DbFlags when a table is open will generate an exception.

Q. Do I have to make my conduit a DLL file? Can I make it part of an executable? Or use your Palm table component to access a Palm table outside of a HotSync operation?
Possibly. The new COM interface access method mean that a conduit could be embedded inside an executable. You could thus create your own COM conduit skeleton inside your executable, and then in your HotSync Synchronisation method still create instances of the library's remote table component to simplify your development.

No matter what the case, though, Palm tables can only be accessed during a Palm-initiated HotSync. You can't simply drop a Palm table component into an application and start reading Palm tables whenever you want.

Q. How do I configure POSE to work with the conduit library?
I'm no expert in POSE, but you'd configure it in exactly the same way as you would for it to work with any conduit. There are two options. The first is to use a loop-back plug to join two serial ports of a computer, where POSE is working with one of the serial ports, and HotSync is set to the other; you could also probably use two separate computers to equal effect. The other option would be to use the TCP/IP synchronisation option of both POSE/HotSync, to synchronise across the network, even if the "network" is actually only your own computer.

Q. My conduit locks up in the middle of synchronisation. Can you help me find the problem?
Unfortunately, there's generally little I can do help people fix problems with their conduit. Now moreso than in the past, it's unlikely to be my library causing the problems. So all I can suggest is to run your conduit slowly through the debugger. Test each part little by little. Add messages to the log at various points in your conduit, and narrow down where the problem is occurring. Once you've identified what's causing the problem, you're part way to fixing it.

Q. Do have versions of the library for Delphi * or Borland C++ Builder *?
Currently I have package files for Delphi 4 through 7. The library won't work with Delphi versions before 4.0 - it uses several features that were introduced in Delphi 4, and it would be too great an effort to port to earlier versions of Delphi, especially given the small number of people still using it. Sorry about that. It also won't work in Kylix - the library needs the Palm HotSync DLLs to work, and there's no equivalent under Linux.

As for Borland C++ Builder, as long as it's at least version 4.0, I presume that you can import the source directly in. You may need to create your own BCB package and include all the source files, but this should be a fairly simple process.

Q. How did you get the field specifications for the Address book or Memo application on the Palm?
I simply read the source code. All the basic Palm applications are provided with full source code as part of the CDK (Conduit Development Kit), which can be downloaded from Palm OS Developer support. Using that as a guide, I was able to set up a field definition in the provided examples that maps to the Palm application databases.

Q. I've having problems inserting records into the database. They always seem to end up at the end of the table
This is because of limitations in the Sync API interface itself. You cannot add new records into arbitrary positions in a database. You can only add a record at the end of one. That is why, in the library, the table Insert method internally maps to the Append method.

One solution to this problem is to have some form of Id within each record, and then in your Palm application, respond to a launch code of "sysAppLaunchCmdSyncNotify" with code that opens up your database table and sorts it (eg. using DmInsertionSort).

Q. Is it possible to create field definitions for your component at runtime?
Yes it is. Use the TpfgPalmRemoteTable.FieldDefs.Add(..) method to add new fields to the field definitions, and FieldDefs.Clear to clear out any previous definition. Note that field definitions should really only be changed prior to openning a table - it's not advised that you try changing them while a table is open.

Q. I get an error about a mapped field going beyond the end of the physical record?
One of the basic issues with the Palm is that it's database system doesn't have any field structure. Instead, each record is simply a block of data, and it's up to the individual application writer to take care of packing/unpacking the data in their records. The conduit library tries to make things easier for developers by letting them define what data each record contains, and taking care of packing/unpacking data from the records on the Palm.

The error mentioned above occurs when the library tries to decode the raw data from a record to be mapped into a set of fields, but finds that there isn't enough raw data in the record to fill out all the fields that are defined. Generally this will occur if yuor field definitions don't correctly match that of your application on the Palm, or you didn't correctly take into account field alignment issues.

Q. The examples won't compile under Delphi 4. What do I do?
Unfortunately, this is the case. The examples use textual DFMs, which weren't introduced until Delphi 5. Whilst I haven't personally tried it, I presume you could take the following steps:

This should have converted the text of the DFM file into the Delphi 4 binary format for form files.