473,320 Members | 2,107 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,320 software developers and data experts.

Example of webservice file transfer


Can you point me to a simple example of how to transfer a
file (send or receive) using a webservice.

Thanks!

Bob

PS. Pardon my double posting. I also posted to the
webservices forum.
Nov 21 '05 #1
5 5602
Bob,

Can you make this more clear because you have asked webservice and webserver
are you asking about two different methods.

With a webserver you have to read the file, serialize it and than get it it
using a webservice function, deserialize it and than write it to file.

I hope this helps anyhow to get an idea.

Cor
Nov 21 '05 #2
Cor,

I am slowing getting the picture now for how to transfer a file using a
webservice. I have to first load the binary stream of the file into an
XML data set row on the webserver machine then the client application
can reference that webservice to bring the xml dataset over... then I
need to unload the binary row containing the contents and write it to a
file. I guess that is what you are referring to when you
say...serialize - deserialize??
I understand now how it works. Thank you!

Nov 21 '05 #3
Bob,

See as well my other message I just have sent, however about this one, when
it is about dataset you even have not to use a serialize/deserialize method.

You can write it serialized to a file using the dataset.WriteXML method

(When you want a procedure to serialize that easy than I have those as well)

I hope this helps

Cor
Nov 21 '05 #4
Cor,

Maybe in a little while I will ask about a procedure.

But first, do you think it is a good idea to serialize binary files
into rows of a data set?

In one way it seems like it may be inefficient way of moving files to
first put them into a data set with other files only to take them back
out again once the XML data set gets to the client. I have read that
if the files get too big then some people do "chunking" to split
binaries over multiple rows in the dataset so ... "not so much has to
be fit into memory at one time"??? Do you have any advice? Most of my
files are small though (15 to 50KB).

On the other hand I like the idea of deploying these 1,000's of small
files via XML webservice because it will be easier to keep track of
timestamps to control when a file needs to be sent to the client for
update. If I put all these small files in a database with a timestamp
then I can use a single query to determine which files need to be
pulled down to the client via the XML webservice for update.
Implementing a similar update scheme using FTP is not as easy to check
and compare timestamps between server and client because I will need to
parse the timestamps from the filelist to compare correctly to the
client file timestamps. Not all server filelist timestamps are the
same form.

Bob

Nov 21 '05 #5
Bob,

I think that it would be the best to serialize a file to a blob and than do
some compression over it. However I as well never tried to sent that with a
windowsservice.

When I am in doubt, I never bother about a solution until it really gives
problems. Don't forget that in this kind of forums, there are people who can
discuss endless about boxing and unboxing however about real problems that
affect the client, you see them write seldom. A customer thinks that means
that he will accept "some" waiting time when he/she can understand why. It
gives him/her by the way the natural rest moments he/she needs as well.

Your customer is the best test about the performance and feel and look from
your applications from which you can learn the most.

Just my thought,

Cor
Nov 21 '05 #6

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

Similar topics

4
by: Sunny | last post by:
Hi all, I have to prepare a webservice (framework 1.1, C#) and winapp client (fw 1.1, C#). The service will prepare a file and soul send it to the client. Any help in that direction, how to...
1
by: Erik | last post by:
Does anyone know why this happens? When returning the XML string through the webservice the XML string is filled with escape characters: XML string before webservice transfer: <Node...
10
by: ad | last post by:
I want to use WebServer to receive a DataSet from Client with internet. The DataSet is some bigger, there are 50 fields and about 50000 rows in it. Is it OK to do so? Will DotFrameWork or IIS...
4
by: WStoreyII | last post by:
I wish to know how to set it up so that when an xml webservice is called that instead of displaying the xml in the browser it will render it with a xslt file the problem is i dont know how to do...
5
by: mtv | last post by:
Hi all, I have the following code: ================================ Webservice side: public class MyWS: WebService { private myLib.DataObject curDataObject;
6
by: Carlos Lozano | last post by:
Hi, as a background I have an Windows application developed with VS 2003 (c#) that needs to transfer securely data to a MySQL database located on a Linux server. I have created a PHP...
2
by: Praveen | last post by:
Hi All, I have made a webservice in C# and it works fine in my machine. I ran into a crazy problem when I wanted to deploy it in windows 2003 server. I have run "aspnet_regiis.exe -i" to make...
0
by: JJ | last post by:
I have a requirement where I need to transfer a web.config from one webservice to another webservice. The environment for this will be intranet only. I will use a xaml win app client to initiate...
0
by: nano2k | last post by:
Hi I need to automatically update a webservice that is already deployed. That is, when I release a new version of webservice, I want the webservice to automatically update itself. To accomplish...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

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.