Hello folks.
I have a silverlight project that loads a sequence of html files chosen by the user on silverlight radBook.
Since the files are stored on the server, I built a web service to return their byte stream.
Problem is that when I "merge" (or better said, concatenate the byte arrays from stream) the files on server side, it gets all mixed and the single merged file appears corrupted. This problem does not happen if I merge file by file on the client, using radDocument and HtmlProvider.
I tried this approach, calling a web method to return to the client app the file paths from the database, and then, going throughout the list of files and calling the web method to return the stream for each one of them.
I call the methods by attaching an even handler that fires when the Async call to the method is completed.
The first web method works fine, and I can retrieve the paths. But when I pass on to call file by file, the web method does not fire EventCompleted so that I can load the files using radBook.
This only occurs when I call prior to it the first web method that returns the paths; if I call directly the web method to return the stream for a single file, it works fine.
Does anyone have any clue on how do I call a sequence of web methods, and still be able to manipulate the EventCompleted for both of them?
It's a pretty small project, if needed I could write here some of the main lines of the code the explain it better.
I'd appreciate any help! Many thanks in advance.
I have a silverlight project that loads a sequence of html files chosen by the user on silverlight radBook.
Since the files are stored on the server, I built a web service to return their byte stream.
Problem is that when I "merge" (or better said, concatenate the byte arrays from stream) the files on server side, it gets all mixed and the single merged file appears corrupted. This problem does not happen if I merge file by file on the client, using radDocument and HtmlProvider.
I tried this approach, calling a web method to return to the client app the file paths from the database, and then, going throughout the list of files and calling the web method to return the stream for each one of them.
I call the methods by attaching an even handler that fires when the Async call to the method is completed.
The first web method works fine, and I can retrieve the paths. But when I pass on to call file by file, the web method does not fire EventCompleted so that I can load the files using radBook.
This only occurs when I call prior to it the first web method that returns the paths; if I call directly the web method to return the stream for a single file, it works fine.
Does anyone have any clue on how do I call a sequence of web methods, and still be able to manipulate the EventCompleted for both of them?
It's a pretty small project, if needed I could write here some of the main lines of the code the explain it better.
I'd appreciate any help! Many thanks in advance.