Cache Image / Picture

Discussion in 'ASP .Net' started by Stan SR, Jan 24, 2007.

  1. Stan SR

    Stan SR Guest

    Hi,

    I use a repeater that calls a page where I display an image (sorry for my
    english ;) )

    This page performs a webRequest to capture a jpg file
    And with the result I resize the picture and make OutputStream

    I have 2 questions :

    1) How can I check If the picture exists ?

    2) Is it possible to store the result in a Cache System
    I ve tried,
    Bitmap myPicture =(Bitmap)Cache[myPictureId];
    if (myPicture ==null){
    myPicture=myThumbnail;
    Cache.Insert(myPictureId,myPicture);
    }
    But I dont know how to send the result

    With my initial code (without the cache), I used
    Response.ContentType="image/jpeg";
    myThumbnail.Save(Response.OutputStream,blabla,blabla);

    Any idea ??

    Stan
    Stan SR, Jan 24, 2007
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jeff Nokes

    Cache::Cache Stale Segments

    Jeff Nokes, Sep 30, 2003, in forum: Perl
    Replies:
    0
    Views:
    559
    Jeff Nokes
    Sep 30, 2003
  2. DesignerX

    Page.Cache vs HttpContext.Current.Cache

    DesignerX, Jan 20, 2004, in forum: ASP .Net
    Replies:
    5
    Views:
    8,227
    vMike
    Jan 20, 2004
  3. Raydog
    Replies:
    3
    Views:
    22,180
    Raydog
    Apr 9, 2004
  4. Replies:
    8
    Views:
    1,225
    Mick White
    Apr 19, 2005
  5. Jake Barnes
    Replies:
    7
    Views:
    189
    Evertjan.
    Dec 8, 2005
Loading...

Share This Page