LogoASPAlliance: Articles, reviews, and samples for .NET Developers
Image Web Service
by Chris Garrett
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days): 17872/ 29

Image Web Service

This is a practical example of how a web service can use GDI+ functionality to return image data and how you can then consume this web service.

The web service creates an image based on the requested text, font, alignment and colours that you supply in a call to the DrawText webmethod.

Your image data is then returned as an array of bytes which you then must reconstruct in your client application using an input stream.

As you will see if you view the source, the client application is very simple. This code could be simplified even further by putting the stream and bitmap creation code into a custom proxy rather than relying on the proxy created by the .NET command line tools.

To use the web service in your own applications, download the .dll and put it in your web application bin directory or add a web reference in Visual Studio.NET


Try it out

View Source


Product Spotlight
Product Spotlight 

©Copyright 1998-2020  |  Page Processed at 2020-07-05 10:44:08 PM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search