akshu
November 30th, 2008, 04:14 AM
Hi,
I am connecting funambol server(Http Session).
I want to add some contacts to funambol server(To Synchronize Contact with Client).
I m sending data through below mention API.
HttpSendRequest(hInternet, headers, wcslen(headers), szHeader,wcslen(szHeader));
szHeader = "Data contains"
I am checking the response using InternetReadFile( hInternet, buffer, 10000, &dwRead )
Reading buffer data? Is this a wrong way?
If yes then : How to check the response?
Please reply me if information is not sufficient.
Thanks in Advance.
Data Contains :-
<SyncML>
<SyncHdr>
<VerDTD>1.1</VerDTD>
<VerProto>SyncML/1.1</VerProto>
<SessionID>210</SessionID>
<MsgID>1</MsgID>
<Target>
<LocURI>http://abc.dyndns.org:8080/funambol/ds</LocURI>
</Target>
<Source>
<LocURI>111111111111111</LocURI>
<LocName>guest</LocName>
</Source>
<Cred>
<Meta>
<Format>b64</Format>
<Type>syncml:auth-basic</Type>
</Meta>
<Data>Z3Vlc3Q6Z3Vlc3Q=</Data>
</Cred>
<Meta>
<MaxMsgSize>10000</MaxMsgSize>
<MaxObjSize>64000</MaxObjSize>
</Meta>
</SyncHdr>
<SyncBody>
<Add>
<CmdID>15</CmdID>
<Meta>
<Format xmlns="’syncml:metinf’">chr</Format>
<Type xmlns="’syncml:metinf’">text/x-vcard</Type>
</Meta>
<Item>
<Source>
<LocURI>./2</LocURI>
</Source>
<Data>
BEGIN:VCARD
VERSION:2.1
FN:Bruce Smith
N:Smith;Bruce
TEL;WORK;VOICE:+1-919-555-1234
TEL;WORK;FAX:+1-919-676-9876
EMAIL;INTERNET:bruce1@host.com
END:VCARD
</Data>
</Item>
</Add>
<Final></Final>
</SyncBody>
</SyncML>
I am connecting funambol server(Http Session).
I want to add some contacts to funambol server(To Synchronize Contact with Client).
I m sending data through below mention API.
HttpSendRequest(hInternet, headers, wcslen(headers), szHeader,wcslen(szHeader));
szHeader = "Data contains"
I am checking the response using InternetReadFile( hInternet, buffer, 10000, &dwRead )
Reading buffer data? Is this a wrong way?
If yes then : How to check the response?
Please reply me if information is not sufficient.
Thanks in Advance.
Data Contains :-
<SyncML>
<SyncHdr>
<VerDTD>1.1</VerDTD>
<VerProto>SyncML/1.1</VerProto>
<SessionID>210</SessionID>
<MsgID>1</MsgID>
<Target>
<LocURI>http://abc.dyndns.org:8080/funambol/ds</LocURI>
</Target>
<Source>
<LocURI>111111111111111</LocURI>
<LocName>guest</LocName>
</Source>
<Cred>
<Meta>
<Format>b64</Format>
<Type>syncml:auth-basic</Type>
</Meta>
<Data>Z3Vlc3Q6Z3Vlc3Q=</Data>
</Cred>
<Meta>
<MaxMsgSize>10000</MaxMsgSize>
<MaxObjSize>64000</MaxObjSize>
</Meta>
</SyncHdr>
<SyncBody>
<Add>
<CmdID>15</CmdID>
<Meta>
<Format xmlns="’syncml:metinf’">chr</Format>
<Type xmlns="’syncml:metinf’">text/x-vcard</Type>
</Meta>
<Item>
<Source>
<LocURI>./2</LocURI>
</Source>
<Data>
BEGIN:VCARD
VERSION:2.1
FN:Bruce Smith
N:Smith;Bruce
TEL;WORK;VOICE:+1-919-555-1234
TEL;WORK;FAX:+1-919-676-9876
EMAIL;INTERNET:bruce1@host.com
END:VCARD
</Data>
</Item>
</Add>
<Final></Final>
</SyncBody>
</SyncML>