473,387 Members | 1,481 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Could we send a compressed file (.zip) to server by web service?

ad
I have a compressed file in client.
How could we send this compressed file (.zip) to server by web service?
Nov 19 '05 #1
6 3080
ad wrote:
I have a compressed file in client.
How could we send this compressed file (.zip) to server by web service?


You might wanna take a look at WSE... it allows for DIME requests which
supports binary attachments to a SOAP request/response, among other things.

--
Thanks,

Martijn Saly
Nov 19 '05 #2
ad
What is WSE?
"Martijn Saly" <ma*****@thany.org>
???????:Ob**************@TK2MSFTNGP12.phx.gbl...
ad wrote:
I have a compressed file in client.
How could we send this compressed file (.zip) to server by web service?


You might wanna take a look at WSE... it allows for DIME requests which
supports binary attachments to a SOAP request/response, among other
things.

--
Thanks,

Martijn Saly

Nov 19 '05 #3
Any file can be sent as a byte array, so declare the Web service something
like this:
Public Sub UpLoadFile(ByVal FileBytes() As Byte, ByVal FileName As String)
Then on the client side, read the file into a byte array (use
IO.File.OpenRead) and call the Web service.
On the server side write the byte array to disk .

"ad" <fl****@wfes.tcc.edu.tw> wrote in message
news:ey**************@TK2MSFTNGP09.phx.gbl...
I have a compressed file in client.
How could we send this compressed file (.zip) to server by web service?

Nov 19 '05 #4
ad wrote:
What is WSE?
"Martijn Saly" <ma*****@thany.org>
???????:Ob**************@TK2MSFTNGP12.phx.gbl...
ad wrote:
I have a compressed file in client.
How could we send this compressed file (.zip) to server by web service?


You might wanna take a look at WSE... it allows for DIME requests which
supports binary attachments to a SOAP request/response, among other
things.

--
Thanks,

Martijn Saly


See here:

http://msdn.microsoft.com/webservice...s/building/wse

It's a library that has to be installed on the server, so I hope that's not
a problem.

--
Thanks,

Martijn Saly
Nov 19 '05 #5
Chris Botha wrote:
Any file can be sent as a byte array, so declare the Web service something
like this:
Public Sub UpLoadFile(ByVal FileBytes() As Byte, ByVal FileName As String)
Then on the client side, read the file into a byte array (use
IO.File.OpenRead) and call the Web service.
On the server side write the byte array to disk .


That would that under water, the file's contents would be B64-encoded on the
client side and B64-decoded on the server side. That's a huge overhead...

--
Thanks,

Martijn Saly
Nov 19 '05 #6
ad
My initinal purpose is that:
I have to transfer dataset to server by web service. The rows in the dataset
is so huge(over 8000 records)

Is it worth to compressed before transfer?

"Martijn Saly" <ma*****@thany.org>
???????:O$**************@TK2MSFTNGP10.phx.gbl...
Chris Botha wrote:
Any file can be sent as a byte array, so declare the Web service
something like this:
Public Sub UpLoadFile(ByVal FileBytes() As Byte, ByVal FileName As
String)
Then on the client side, read the file into a byte array (use
IO.File.OpenRead) and call the Web service.
On the server side write the byte array to disk .


That would that under water, the file's contents would be B64-encoded on
the client side and B64-decoded on the server side. That's a huge
overhead...

--
Thanks,

Martijn Saly

Nov 19 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Usman | last post by:
Hi I have a window service written in C#. I have another application that requires a lengthy process to be performed like taking backup. How can I make this lengthy process be performed by...
1
by: Chris | last post by:
Hi, In ASP.NET do I want to sent a file from the server to the client and tried the following : byte sendData = Encoding.ASCII.GetBytes(strXmlContent); // strXmlContent is a string that...
10
by: Alphonse Giambrone | last post by:
I am trying to develop a web service to accept a file uploaded via http post from a vba (Access) application. Thanks to helpful links in a vb newsgroup and my previous work with WinInet api I was...
4
by: jf li | last post by:
I have a Asp.net web application and a Asp.net Web service application. The Web application is using HtmlInputFile to get a 50M size of file selected by end user, read the data of this file and...
1
by: Ritesh Raj Sarraf | last post by:
Hi, The program downloads the files from the internet and compresses them to a single zip archive using compress_the_file(). Upon running syncer() which calls the decompress_the_file(), the...
2
by: antonyliu2002 | last post by:
I am testing AJAX. I've downloaded the AJAX Extension and the CTP December package and installed on BOTH my development machine and the production server. Then I created a very very simple web...
1
by: Alan Sloan | last post by:
I have written a Web Service that interacts with a COM component to extract a file from another system. Basically the Web Service accepts a part number and a rev and extracts the file to a...
6
by: =?Utf-8?B?U2NvdHQgVHJpY2s=?= | last post by:
I followed the instructions from MSDN for Webclient UploadFile and I get an error: Could not find file 'C:\testfile.xls'. If I add the file (c:\testfile.xls) to the server I do not get the error...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.