Using stream HttpRequestClass

  • Thread starter Thread starter Alexander Inochkin
  • Start date Start date
A

Alexander Inochkin

Hi!

I'm using HttpRequestClass on .NET and .NET Compact. I made request and get
incomming data.
But data feed is very slow. But I need to get data as early as possible. But
behavior the code under
this two platform is different... On .NET I read all available bytes, less
then BUFFER_SIZE, as they come.
On .NET Compact (emulator and real device) I get BUFFER_SIZE bytes as first
result. I wait until all bytes
up to BUFFER_SIZE will be read...

How can I get behavior on .NET Compact like on .NET?
I need to get all available bytes without waiting filling all buffer....


Example of code:

HttpWebResponse resp = ...;
Stream responseStream = resp.GetResponseStream();
responseStream.BeginRead(buffer, 0, BUFFER_SIZE, new
AsyncCallback(ReadCallBack), ...);


private void ReadCallBack(IAsyncResult asyncResult)
{
...
int readCount = responseStream.EndRead( asyncResult );

}
 
Hello Alexander,

Thanks for your post. Currently I am finding resources and trying to assist
you on this issue. We will update you as soon as possible.

Regards,

HuangTM
Microsoft Online Partner Support
MCSE/MCSD

Get Secure! -- www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
Hi Alex,

You would probably be most likely to get an answer to this in the microsoft.public.dotnet.framework.compactframework newsgroup as
there will most likely be a larger pool of respondants that are familiar with the Compact Framework.


Scot Rose, MCSD
Microsoft Visual Basic Developer Support
Email : (e-mail address removed) <Remove word online. from address>

This posting is provided “AS IS”, with no warranties, and confers no rights.

Get Secure!
http://www.microsoft.com/security
http://www.microsoft.com/protect


--------------------
 
Back
Top