PC Review


Reply
Thread Tools Rate Thread

"byteCount" error when threading WebClient.OpenRead

 
 
JS
Guest
Posts: n/a
 
      22nd Nov 2005
Has anyone encountered the error:
"Non-negative number required.
Parameter name: byteCount"

When threading and executing the WebClient.OpenRead method? I do not
encounter the error when I execute the threaded calls in a linear
fashion.

 
Reply With Quote
 
 
 
 
JS
Guest
Posts: n/a
 
      22nd Nov 2005
To add...

StackTrace:

" at System.Text.UTF8Encoding.GetChars(Byte[] bytes, Int32 byteIndex,
Int32 byteCount, Char[] chars, Int32 charIndex, UTF8Decoder decoder)
at System.Text.UTF8Decoder.GetChars(Byte[] bytes, Int32 byteIndex,
Int32 byteCount, Char[] chars, Int32 charIndex)
at System.IO.StreamReader.ReadBuffer(Char[] userBuffer, Int32
userOffset, Int32 desiredChars, Boolean& readToUserBuffer)
at System.IO.StreamReader.Read(Char[] buffer, Int32 index, Int32
count)
at System.IO.StreamReader.ReadToEnd()
at JBPS.JBFeeder.Remote.GetHTTPData() in
C:\JBCode\JBFeeder\Code\Current\JBPS.JBFeeder.Utilities\Remote.vb:line
629"

 
Reply With Quote
 
JS
Guest
Posts: n/a
 
      23rd Nov 2005
Answer found...RTFM. Doh!


JS wrote:
> To add...
>
> StackTrace:
>
> " at System.Text.UTF8Encoding.GetChars(Byte[] bytes, Int32 byteIndex,
> Int32 byteCount, Char[] chars, Int32 charIndex, UTF8Decoder decoder)
> at System.Text.UTF8Decoder.GetChars(Byte[] bytes, Int32 byteIndex,
> Int32 byteCount, Char[] chars, Int32 charIndex)
> at System.IO.StreamReader.ReadBuffer(Char[] userBuffer, Int32
> userOffset, Int32 desiredChars, Boolean& readToUserBuffer)
> at System.IO.StreamReader.Read(Char[] buffer, Int32 index, Int32
> count)
> at System.IO.StreamReader.ReadToEnd()
> at JBPS.JBFeeder.Remote.GetHTTPData() in
> C:\JBCode\JBFeeder\Code\Current\JBPS.JBFeeder.Utilities\Remote.vb:line
> 629"


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
WebClient, DownloadFile, OpenRead Does not retrive last modify file Harvey Triana Microsoft ASP .NET 4 8th Feb 2008 06:46 PM
WebClient OpenRead & Threading Issue JS Microsoft Dot NET Framework 7 22nd Nov 2005 09:03 PM
WebClient.OpenRead questions =?Utf-8?B?Sm9obkJhdHRl?= Microsoft Dot NET 0 29th Apr 2004 09:31 PM
problem with WebClient.OpenRead Helen Abell Microsoft Dot NET 0 2nd Dec 2003 09:51 AM
question about WebClient.OpenRead Seymen Ertas Microsoft Dot NET 5 26th Nov 2003 01:13 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:47 PM.