I am having problem with networking on my palm. I am trying to develop a
project that will connect to a url that will be determined later for data. I
am actually trying to establish a http connection. I am using a palm
emulator and and Apache web server. The web server receives my request
because the access log shows my request and the number of bytes it sent. But
I can't receive any data. Below is my code. It uses the NetU functions.
error= SysLibFind("Net.lib",&AppNetRefnum);
NetLibOpen(AppNetRefnum,&error);
Socket1 = NetUTCPOpen(address,service,80);
memBuf = MemHandleNew(35);
rBuf = (char*) MemHandleLock(memBuf);
temp=NetUWriteN(Socket1,(UInt8*)buffer,StrLen(buffer));
StrIToA(sent,temp);
temp= NetUReadN(Socket1,(UInt8*)rBuf,30);
StrIToA(receive,temp);
NetLibSocketClose(AppNetRefnum, Socket1, 100, &error);
NetLibClose(AppNetRefnum, 1);
_________________________________________________________________
Send and receive Hotmail on your mobile device: http://mobile.msn.com
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/support/forums/