Members

Technology Zones

IBM Learning Center

Articles

Hosted By

MaximumASP

Info

Rated
Read 63,187 times

Contents

Related Categories

Creating Images on the Fly with ASP.NET - Introduction

fengtui

Introduction

Before the advent of the .Net framework, creating images on the fly for a web browser was a tedious task. Now, thanks to the .Net framework, creating images on the fly is a simple task. This article will provide the reader with the fundamentals necessary to start developing dynamic images with the .Net framework.

Creating dynamic images with the .Net framework is a four-step process. First, set the content-type of the aspx file to an image type. Second, get an instance of the Graphics object from a Bitmap. Third, draw on the Graphics object. Four, save the Bitmap to an output stream.

The default content-type value for an aspx file is "text/html". If we want to output an image, say an GIF, we need to set the content-type to "image/gif". We simply add the following to the top of our aspx page.

<%@ Page ContentType = "image/gif"%>

Comments

  • Re: [2569] Creating Images on the Fly with ASP.NET

    Posted by fatti on 22 Oct 2006

    This has just solved a problem I have spent two weeks trying to solve.
    Even thought it was in VB and I needed it in C# I was still able to use
    it as converting it over was easy enough.



    Ex...

  • Alternativly use ImageIN free image library

    Posted by ananasgroup on 26 Sep 2004

    You can skip this and just d/l ImageIN. Its an amazing free multi layer composition object which allows you to do many things... (http://www.cyberbob.com)

  • Also Intrested

    Posted by KrishManohar on 10 Mar 2004

    I am Also intrested in this idia!

    Mosly dealing with online desing, submited to my e-mail.

    I am sure it's dealing with Java Script or ASP i have some Links to a example of what i am looking for:...

  • Posted by magnetmagic2 on 10 Mar 2004

    [quote][1]Posted by [b]lea[/b] on 2 Jan 2003 08:52 AM[/1]
    Hi I am trying to create an online design system for business cards. the user selects the template with the design already made from the data...

  • Business Card

    Posted by farouk on 20 Jun 2003

    Hi
    Can yuo please tell me what technology or code you used for handling business card design system. I would really appreciate your help
    I are trying to do something very similar please
    Farouk