Hi,
I have 2 web service projects called "CLient_Side" and "Server_side".
"Client_Side" has a web reference to "Server_side" but its not the other way
around (i.e Server_side will not have a reference to Client_side).
I want to pass files between the 2 web services.
For moving file from Server_Side to Client_Side, I did the below:
1. On Server_side, I read the file contents as a memory stream
2. Attached it as a DIME attachment to Response Soap Context
3. On Client_Side, got Server_Side. ResponseSoapContext.Attachments and
got the DIME attachment's memory stream and wrote to a file.
This works perfectly fine.
Now the problem is how to pass file's contents from client_side to
Server_side.
The Client_side can read the file's contents and attach the memory stream to
the response soap context object.
respContext.Attachments.Add(dimeAttach)
But since the Server_side has no reference to Client_Side, how can I receive
the contents on server_side?
I can't do a
client_side.ResponseSoapContext.Attachments bcos it has no reference to
client_side.
How can I pass the file's contents from client_side to server_side.
Thanks for any help..
Jason - 23 Aug 2005 12:19 GMT
As I understand it you don't need access to client side, just use:
RequestSoapContext.Current.Attachments.