Skip to main content
Home Forums Silverlight Programming Report a Silverlight Bug AssemblyPart.Load needs a seekable stream
1 replies. Latest Post by ksleung on June 26, 2009.
(0)
br1
Member
4 points
25 Posts
06-26-2009 11:21 AM |
Silverlight crashes when calling AssemblyPart.Load with a stream with CanSeek==false. This should be documented or work-arounded.
ksleung
Contributor
5366 points
1,028 Posts
06-26-2009 11:56 AM |
The workaround is to create a memory stream, read the whole non-seekable stream into it, and call AssemblyPart.Load() with the memory stream. I can see why AssemblyPart.Load() needs a seekable stream, and even if SL supports non-seekable, it will be done by doing some internal buffering using a similar mechanism anyway...
But I agree with your point about documentation... SL needs better documentation, as well as better messages when exception happens.