• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
  • Mike London

how to display an image using drawImage()

Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i have successfully displayed image using the below method
Image img = ImageIO.read(new File("F:\\x.jpg"));

my question is, i am reading an image from database and i want to display that particular image using drawImage() method

here is the code how am retrieving image from database and storing on hard disk
byte[] fileBytes;
fileBytes = rs.getBytes(2);
OutputStream targetFile = new FileOutputStream("e:/dp.jpg");

i don't want to store the image on hard disk just i want to display that image using drawImage().
please help me -thanks in advance.
Don't get me started about those stupid light bulbs.
    Bookmark Topic Watch Topic
  • New Topic