Write a handler that emits the JPG as the respone. Here's an example: http://staff.develop.com/ballen/blog/PermaLink.aspx?guid=2d8b430b-8361-416d- 9df8-9aff48bf2481
-Brock http://staff.develop.com/ballen > -----Original Message----- > From: Discussion of advanced .NET topics. > [mailto:[EMAIL PROTECTED] On Behalf Of > Simon Cansick > Sent: Monday, October 16, 2006 11:54 AM > To: ADVANCED-DOTNET@DISCUSS.DEVELOP.COM > Subject: [ADVANCED-DOTNET] Image Response using ASP.Net > > I'm looking to optimise a web application that produces images on the > fly. > > My server side class has a method that returns a Bitmap > object (.Net 2, > C# Class). When the user requests the page, this method is > invoked and > the generated image is displayed in the response. I do this > by firstly > converting it to Jpeg, writing it to disk, then referencing > the new Jpeg > file using an imageControl on my asp page. > > This is a bit clunky, I want to avoid writing to disk. Has anyone got > any good techniques for writing an image out directly from > memory to the > response? > > Thanks for any advice. > > Simon James. > > > The contents of this email are confidential to the intended recipient > and may not be disclosed. Although it is believed that this email and > any attachments are virus free, it is the responsibility of > the recipient to confirm this. > > Smith & Williamson Corporate Finance Limited - A member of > the London Stock Exchange. > A member of M&A International Inc. http://www.mergers.net > Registered in England No. 4533970. Authorised and regulated > by the Financial Services Authority > Smith & Williamson Investment Management Limited, Registered > No. 976145. Authorised and regulated by the Financial > Services Authority. > Smith & Williamson Pension Consultancy Limited - Independent > Intermediary. Registered No. 3133226. Authorised and > regulated by the Financial Services Authority. > Smith & Williamson Fund Administration Limited, Registered > No. 1934644. Authorised and regulated by the Financial > Services Authority. > Smith & Williamson Limited - A member of Nexia International. > Registered in England No. 4534022. Regulated by the > Institute of Chartered Accountants in England & Wales for a > range of investment business activities. > NCL Investments Limited, Registered No. 1913794. > Member of the London Stock Exchange authorised and regulated > by the Financial Services Authority. > > Registered Office: 25 Moorgate, London EC2R 6AY > Telephone: 020 7131 4000 http://www.smith.williamson.co.uk > > Nexia Smith & Williamson Audit Limited - A member of Nexia > International. Registered in England No. 4469576. > Nexia Smith & Williamson Audit Limited is a company > registered to carry out audit work and is regulated for a > range of investment activities by the Institute of Chartered > Accountants in England and Wales. Smith & Williamson Limited > is a separate company that provides professional resources > and certain services to Nexia Smith & Williamson Audit > Limited under the terms of a formal agreement on an arm's > length basis. > > Registered Office: 25 Moorgate, London EC2R 6AY > Telephone: 020 7131 4000 http://www.nexiasmith.williamson.co.uk > > All telephone calls are recorded for business purposes. > > =================================== > This list is hosted by DevelopMentor http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com > =================================== This list is hosted by DevelopMentorĀ® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com