Brian Smith a �crit :

> On Fri, 12 Sep 2003, Luc Le Blanc wrote:
>
> > Did you try multiple records beaming on OS 3.5?
>
> Yes, I did.  Worked beautifully.
>
> > The book does not mention anything about OS 4.0 but the Palm OS
> > Reference states that ExgSend could not be used to send multiple objects
> > before OS 4.0. I understand this means that once connected, I'm allowed
> > to call ExgSend repeatedly only until I've sent the byte count I
> > indicated when opening the socket. Since I don't know prior to sending
> > how many bytes I want to send, I would have to open the scokect with the
> > size of the first record, call ExgSend until the first record is sent,
> > disconnect, and repeat the operation for the next record. Or am I
> > missing something? If so, what is this warning about multiple objects
> > and OS 4.0?
>
> You're missing the fact that the multiple-object beaming support in 4.0
> involves a call to ExgConnect() (ignoring errors, since some exchange
> libraries don't support it but do support multiple objects), then multiple
> calls to ExgPut() before your ExgDisconnect()  call.  If you're only
> calling ExgPut() once, then you're only sending one object in that
> context, no matter how many ExgSend() calls you make, or how many records
> you manage to encode in what you're sending.  All of this information is
> in the 2nd Companion document that comes with the latest SDK.
>
> In the examples in the book, at least in the edition I have, ExgPut() is
> only being called once, no matter how many records you're sending.

After my last post, I understood that "objects" to the Programmer's Companion
are not so much single records in a series, but rather whole DBs, files, etc.
Thus, a bunch of records beamed from a single DB is one object. I realized
that, reading about BeamPro Expo, an application that puts your Palm into an
automatic and continuous beam mode (perfect for distributing a software in an
exhibition). In order to beam several PRC's at once with pre 4.0 Palm OS, they
bundle all these objects into a single filestream before beaming it.

Thanks for the explanation. Now let's go back to implementing this beam
feature.


--
Luc Le Blanc


--
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to