Retrieve jpg images from archive

Hi Gurus,
I am working in a Biller Direct project.I have a requirement in which scanned images stored in archive needs to be displayed whenever user clicks on a hyper link.SAP documentation says that we can use BADI EBPP_INVOICEDETAIL for this.I am successfully able to retrieve PDF docs from archive.But not sure how to achieve Jpg files.
Any help....
Regards,
Raghu.

hi
just have a look at this documentation
http://help.sap.com/saphelp_nw04/helpdata/en/f5/9561fbf3b111d1955b0000e82deb58/frameset.htm
it will answer all your queries
regards
Aakash Banga

Similar Messages

  • How to retrieve am image from database

    hi ,
    i hav a requirement that, i hav to store and retrive an image from database(postgresql)and palce it on JLabel.i successfully stored an image into database .while retrieving an image from database im not getting the image .please any one can help me how to retrieve an image and place it in JLabel.
    This the code for inserting an image:
    Class.forName("org.postgresql.Driver");
    Connection conn = DriverManager.getConnection("jdbc:postgresql://localhost:port/database", "username", "pwd");
    System.out.println("Connection established");
    String INSERT_PICTURE = "insert into imagedata(imageid,data) values (?, ?)";
    FileInputStream fis = null;
    PreparedStatement ps = null;
    try {
    conn.setAutoCommit(false);
    File file = new File("photo.jpg");
    fis = new FileInputStream(file);
    ps = conn.prepareStatement(INSERT_PICTURE);
    ps.setInt(1, 2);
    ps.setBinaryStream(2, fis, (int) file.length());
    ps.executeUpdate();
    conn.commit();
    catch(Exception ex)
    ex.printStackTrace();
    finally {
    ps.close();
    fis.close();This is the code for retrieve an image :
    Class.forName("org.postgresql.Driver");
    Connection conn = DriverManager.getConnection("jdbc:postgresql://localhost:port/database", "username", "pwd");
    byte[] imgbytes = null;
    String INSERT_PICTURE = "select imageid,data from imagedata ";
    Statement stmt=(Statement) conn.createStatement();
    try {
    ResultSet rs=stmt.executeQuery(INSERT_PICTURE);
    while(rs.next())
    System.out.println(rs.getString(1));
    InputStream file=rs.getBinaryStream(2);
    System.out.println("FILE : "+file);
    catch(SQLException a)
    finally {
    stmt.close();please anyone can help meee
    thanks

    You basically save a File to the database, so you can just re-write the data from the file back temporarily and load it into the application using the ImageIO class
    // create necessary connection and statement objects
    // retrieve image column
    ResultSet rs = stmt.executeQuery("SELECT Image FROM dataTable");
    rs.next();
    Blob imageData = rs.getBlob("Image");
    if( imageData != null ) {
        try {
            File tmpFile = new File("tmpImage");
            FileOutputStream fos = new FileOutputStream(tmpFile);
                fos.write( imageData.getBytes(1L, (int)imageData.length()) );
                fos.close();
            tmpFile.deleteOnExit();
            ImageIcon icon = new ImageIcon( ImageIO.read(tmpFile) );   
            JOptionPane.showMessageDialog(null, icon);
        } catch(IOException ioe) {
            ioe.printStackTrace();
            JOptionPane.showMessageDialog(null, "Failed To Load Image Data", "Load Error",
                    JOptionPane.ERROR_MESSAGE);
    }ICE

  • Any way to retrieve this image from my cache? When saved it only saves as a 1.7KB blank file.

    I'm trying to retrieve an image from Firefox's cache but so far have had no luck in doing so. The picture was hosted on imageshack and I had it open in a window but when I refreshed the page several hours later it was gone. I refreshed the page several more times, tried messing with the url to see if that did anything, but no luck. I haven't cleared anything on Firefox so I'm hoping there's some way I can recover it from the cache.
    I followed the instructions on this page: http://groups.google.com/group/mozilla.support.firefox/msg/73bab3fb55ac5b42
    However, when I right clicked the URL and chose "Save Link As..." it only saved a 1.7KB file that none of my photo editing programs can recognize or open. I've tried going to cache entries for other image links and saving them and when I choose Save Link As for those they save just fine, and in full size, so I'm not sure why this one won't work...I'm using Offline Mode so I'm not sure why the picture no longer being hosted online should make a difference one way or the other. I'm just hoping that my act of refreshing the page and nothing being there didn't overwrite the cache file and thus erase the cache'd image.
    So is there any hope of retrieving this picture or is it gone for good?

    Hi.
    Once the image in question is replace with another one, the old one is erased. That is to say, if you open an image, say www.domain.com/image.png, and it's a 200x200 image, then you close it, it's still on cache, and you can access it through the cache. But if the image is changed in the server, that same exact url, and you access it again, at you see a 250x200 image (just an example), then the 200x200 is gone forever.
    Your hope is that you never accessed the same URL again, so the old cache wasn't erased. If you know the url of the image, simply select offline mode (File > Work Offline, I think) and access its url. It will load the cached version and not check for the online one. Only if there is a cached version, of course.
    I hope this helps.

  • Creating a .jpg image from with in the J2ME app

    Hi,
    I want to send a document to the printer over bluetooth to print.
    For that I searched on net, but couldn't find any APIs supported by J2ME to print it. I also found a link http://www.hcilab.org/documents/tutorials/Brother/ where I found that I can send the data by creating an image and then writing data (text or image ) in to it, and then sending that image to print.
    Image img = Image.createImage(816, 40);
    Graphics g = img.getGraphics();
    g.setColor(0, 0, 0);
    g.setFont(Font.getFont(Font.FACE_PROPORTIONAL, Font.STYLE_BOLD,Font.SIZE_LARGE));
    g.drawString("Printing test from "
                             + System.getProperty("microedition.platform") + " on "
                             + new Date(), 10, 10, 0);
    driver.print(img, btAddr);This code is working fine on this printer.
    I am using HP 460cb printer, and I tried the same thing, but am not getting any results. Can any one of you tell me what mistake am I making.
                    Image blankImage = Image.createImage(SpotBilling.MAX_IMG_WIDTH, SpotBilling.MAX_IMG_HEIGHT);
                    Graphics g = blankImage.getGraphics();
                    g.setColor(0,0,0);
                    g.setFont(Font.getFont(Font.FACE_PROPORTIONAL, Font.STYLE_PLAIN, Font.SIZE_SMALL));
                    g.drawString("Printing test on Wednesday - 18th Jan, 2006", 10, 50, Graphics.TOP|Graphics.LEFT);
                    g.drawImage(imgTest, 60, 150, Graphics.HCENTER | Graphics.VCENTER);
                    int width = blankImage.getWidth();
                    int height = blankImage.getHeight();
                    int y = 0;
                    os.write(CMD_UNIVERSAL_EXIT);
                    for(int i = 1; i<=height; i++){
                             blankImage.getRGB(temp, 0, width, 0, y, width, 1);
                             byte[] pixels = new byte[width];
                             for (int x = 0; x < temp.length; x++) {
                                  pixels[x] = (byte) ((((temp[x] & 0x00FF0000) >> 16)
                                       + ((temp[x] & 0x0000FF00) >> 8) + (temp[x] & 0x000000FF)) / 3);
                             // Transfer Raster Graphics
                             os.write(TRANSFER_RASTER_DATA);
                             byte[] len = numToDecimal(pixels.length);
                             os.write(len);
                             os.write(DATA);
                             os.write(pixels);
                             y++;
                        }I have another query, if I can not do this. Is there any way I can create a .jpg image from with in the J2ME application.
    I have some text and an image that I get by invoking camera from the code and then capturing a picture. I need to combine them both, and then send it to the printer.
    If there is any way, I can convert this blankImage mentioned above (containing both text and Image), please provide me the solution.
    Any document or any source code is appreciated.
    regards,
    Ashish

    I have succeeded in creating a mutable image that contains text and image (.png), through
                         Image img;
                         img = Image.createImage(50, 60);
         protected void paint(Graphics g){
              g.drawImage(img, getWidth()/2, getHeight()/2, Graphics.HCENTER | Graphics.VCENTER);
              Graphics graph = img.getGraphics();
              graph.setColor(0, 0, 0);
              graph.setFont(Font.getFont(Font.FACE_PROPORTIONAL, Font.STYLE_BOLD,
                             Font.SIZE_LARGE));
              graph.drawString("Printing test from "
                                       + System.getProperty("microedition.platform") + " on ", 10, 10, 0);
              graph.drawImage(image, img.getWidth()/2, img.getHeight()/2,Graphics.HCENTER|Graphics.VCENTER);
              graph.fillArc(0,0,10,10,0, 360);
         }Now I want to create a .jpg image of this img image(Mutable image).
    What I am doing is that,
    1. I am converting this image in to int array, using getRGB() method.
    2. Then I am converting int array in to byte array.
    3. And then I am opening a file(extension is .jpg)
    4. Then I am sending this byte array in to the file which is .jpg
    The .jpg file is getting created, but the data in it is very absurd, like yyyyyyyyyyyyyyyyyyyyyyyy.
    Please help me in this matter.
    Regards,
    Ashish

  • How do I create a JPG image from a clip

    I need to create a jpg image from a movie clip. Is making a freeze frame the same and creating a jpg?

    A jpg image is saved by FCE in a new file, while a freeze frame in FCE is a still picture used for a sequence in a project, but not saved separately.
    To make a jpg, position the playhead in the timeline on the frame you want to save and Export/Using QuickTime Conversion and select Format: Still Image.
    You are asked for a file name.
    To make a freeze frame, position the playhead in the timeline on the frame you want to reuse within the project and Modify/Make Freeze Frame. This leaves a new still in the viewer: you can drag it to the timeline, drag it to the browser, etc.. - However this does not create a separate file but stays embedded in the project where it is used.
    Piero

  • Why wont jpg images from macbook open on Windows PC?

    I have loaded jpg images from my nikon camera into iphoto on macbook pro.
    No editing was done.
    Then i copied then to a usb and attempted to open on a windows pc .
    They wont open in either windows or photoshop on windows pc.
    Can you help please?
    Many thanks
    Dell.

    You may be burning the disk as a data CD. Make sure that you're burning the disk as an Audio CD (iTunes Burning preference). You can also burn an MP3 CD if your tracks are in MP3 format and your player will handle an MP3 disk.
    Hope this helps.

  • Trying to upload DSCF.JPG images from my Mac Pro to Photostream in iPhoto

    I am trying to upload the DSCF.JPG images from my Mac Pro (originally taken on my Fuji Finepix camera) to Photostream in iPhoto.
    I then want these images to load onto my iPhone 5 through iCloud.
    I have tried dragging the images over from a desktop folder to my Photostream folder in iPhoto – no good. They just won't copy over.
    I have dragged the images over from a desktop folder into a new folder in iPhoto – that worked, but I can't then get them transferred or copied over to the iCloud folder.
    Is it the DSCF format that my Photostream doesn't like? Why would that be?
    And does anybody know what I can do about it?
    Thanks so much.

    Hi dinglydell2,
    The picture formats that are supported by Photo Stream are described in this article -
    iCloud: Shared Photo Streams FAQ
    http://support.apple.com/kb/HT5903
    In particular -
    Shared Photo Streams supports JPEG, TIFF, PNG, and most RAW photo formats. On your Mac or PC, your photos are downloaded and stored in full resolution. On your iPhone, iPad, iPod touch, and Apple TV, your Photo Stream photos are delivered in a device-optimized resolution that speeds downloads and saves storage space. While actual dimensions will vary, an optimized version of a photo taken by a standard point-and-shoot camera will have a 2048 x 1536 pixel resolution when pushed to your devices. Panoramic photos can be up to 5400 pixels wide.
    If the Preview application can open your photos, you may be able to export them to a more compatible format.
    Preview 5.x: Convert graphic file types with Preview
    http://support.apple.com/kb/PH5910
    The process is the same for more recent versions of Preview.
    Open a file in Preview, and choose File > Export.
    Choose a file type from the Format pop-up menu. If you don’t see the file type you want, hold down the Option key as you click the Format pop-up menu to see specialized or older formats.
    Depending on the file format you choose, additional options may appear. If you choose JPEG or JPEG 2000, you can adjust the image’s quality. If you choose PDF, you can choose a Quartz filter to apply to the image, and you can encrypt the image so that only those with the password can view it.
    Type a new name, or choose a new location for saving the converted file, and then click Save.
    Thanks for using Apple Support Communities.
    Best,
    Brett L

  • Request a .jpg image from Indesign server via script?

    hello,
    I have a scenario in which I am switching from using QuarkXpress Server to Indesign Server. With Quark Server I am able to request a jpg image from a quark Document. Basically, by providing the right parameters, I can get a JPG preview of what a picture box or text box looks like in the Quark Document.
    I need to do something like this with InDesign Server. Is it possible to write a script specifying an Indesign Document and maybe a TextFrameID or PictureFrame ID and get a JPG rendering of it?
    I know I can export the whole document as a PDF but I need to be able to get images of single textframes/pictureframes or grouped frames.
    Does anyone know if this is possible or how to do this?
    thanks in advance!!!
    -Lloyd

    Or maybe the only way to achieve this (hopefully not, though) is to export the whole document as a JPG, and then find a way to programmatically crop the part I need based on the coordinates of the textframe/pictureframe (or grouped framed) that I need?
    thanks in advance,
    Lloyd

  • Is there any way how to generate JPG image from DNG easily?

    I use PS, FW and Bridge.
    I have often a problem to show images for preview from DNG files.
    Please can you explain me, how to do it as a batch easily? Generate preview images from a whole folder?
    Do you generate JPG in original size or do you archive only DNG?
    Thank you

    Little confused here.  Are you saying you do not get a thumbnail for a DNG and therefore can not view as a preview?
    If you want to batch convert a DNG to a jpeg you can use tools/photoshop/image processor.

  • Retrieve multiple images from database to servlet

    Hi there,
    I try to retrieve more than one images from database to Servlet/JSP . However, I get only one images in the result set. Here is my code. Please Help .
    How do I display more than one images ( multiple rows ) from database to Servlet ?.
    When I retrieve, I got 3 rows of binary data, but I don't know how to display it on the Servlet/JSP pages.
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import java.util.*;
    import java.lang.*;
    import java.sql.*;
    import com.sybase.jdbcx.*;
    public class RetrievePhoto extends HttpServlet {
    static ResultSet rs;
    static CallableStatement NGSstmt = null;
    static Connection NGScon = null;
    static SybDriver _driver = null;
    public void doGet(HttpServletRequest req, HttpServletResponse res) throws
    ServletException, IOException {
    ServletOutputStream os = res.getOutputStream();
    String driver = ""
    String URL = "";
    String Host = "";
    String UN = ""; //assign your username here
    String PW = ""; //assign your password here
    try {
    Class c = Class.forName( driver );
    _driver = (SybDriver) c.newInstance();
    DriverManager.registerDriver( (SybDriver) _driver );
    NGScon = DriverManager.getConnection( URL + Host, UN, PW );
    } catch ( SQLException e ) {
    os.println( "Unable to load the Sybase JDBC driver. " + e.toString() );
    e.printStackTrace(System.out);
    } catch (java.lang.Exception ex) {
    // Got some other type of exception. Dump it.
    os.println("Exception - java lang " + ex.getMessage() );
    String PID = req.getParameter("PID"); //passing parameters from Servlet
    try {
    String SQLcmd = "{call RET_PHOTO_BY_PID(?)}";
    NGSstmt = NGScon.prepareCall( SQLcmd );
    //execute the query
    synchronized (NGSIDBstmt)
    NGSstmt.setString(1, PID); //passing parameter to store procedure
    rs = NGSstmt.executeQuery();
    byte[] stuff = new byte[1024];
    int bytesRead = 0;
    res.setContentType("image/gif");
    InputStream is = null;
    // Get the first row
    while( rs.next() ) {
    is = rs.getBinaryStream("PHOTO");
    res.setContentLength(is.available());
    for (int i=0;; i++) {
    bytesRead = is.read(stuff);
    os.write(stuff);
    if ( bytesRead == -1 ) break;
    rs.close();
    os.flush();
    os.close(); //close outputstream
    } catch ( SQLException sqle) {
    os.println("Error in SQL2Exception" + sqle.getMessage());

    When I retrieve, I got 3 rows of binary data, but I don't know how to display it on the Servlet/JSP pages.I will pick this bit of your post, because you seemed to have several partly-overlapping questions.
    You are going about this wrong. You need to decide what your HTML will look like before you start writing servlet code. In this case you want to have something like a table, with an image in each row, right? Now what does the HTML for that look like? It's a <table> element, and so on, but what about the images? Well this is HTML, so it can't contain the binary images. It has to contains links to the images, and the browser will download the image from each of those links and put all of the downloads together into the page it displays.
    That means you can't do it all with one servlet. You need a main servlet that generates the HTML, with the <table> element and the links to the images. Probably you need some DB calls here to find out how many images you're going to have, but you don't need to get them in this servlet. You just need to generate a link for each of them.
    Then you need a second servlet that gets an image. It's going to get a single row from the DB and return the binary image you read from that row. Make sure to use "image/jpg" or whatever's appropriate instead of "text/html" in your response's content type here.
    I will leave you to carry on from here. First step is to design the HTML that your main servlet will produce; remember that the links it generates need to carry enough information for the second servlet to be able to find the right image in the DB.
    PC&#178;

  • Retrieving Invoice images from Content Server

    Background
    My problem is, that I need to retrieve images from the Content Server and save them on a local drive with a path provided by the user. Metadata that is available for the image includes Object ID and the URL to the image on the server.
    However, the Object ID is not valid for DMS, so the Function Groups for this are invalid. The cl_gui_* function groups have several usable Function Modules, but the URL link provided for the image is something like this:
    http://xxxxxx.xxxxxx.com:XXXX/ContentServer/ContentServer.dll?get&pVersion=0046&contRep=Z2&docId=123AB1C123D12E12345.... etc.
    What makes the cl_gui FM unable to work, is the :, ?, % and & characters in the string - which makes the FMs look at the URL as invalid.
    I have also tried more or less the entire content of FM in the SCMS_* Function Group (containing FMs for the Content Server), but to no avail.
    Question
    So, now to my question: Is there any way to translate the URL provided so the cl_gui FMs can understand it? Or, should I go the other way around and fetch the Invoice Image using the provided Object ID?
    All needed at my program to finish off, is a method to retrieve the given images and save them to a local path.
    I hope the Guru's of the SDN will be able to help me here
    regards
    Anders Haugbølle
    Edited by: Anders Haugbølle on Feb 4, 2009 12:53 PM

    Moving this thread from ERP MM to [Enterprise Resource Planning (ERP) |Enterprise Resource Planning (SAP ERP);

  • How to read  jpg image from a specified path

    Hi
    I am having an image in jpg ext, so i am using File nf = new File(path);to read the image, now i have to place that jpg image in an byte/String array so from that i will save that in to the Oracle DB with BLOB data type, plz answer to this asap with code......
    the following code is not useful i think so...
         String st = "C:\Documents and Settings\Sasi\Desktop\sasi.jpg"    
          File infile = new File(st);
         BufferedImage im = ImageIO.read(infile);
         String[] reader_names = ImageIO.getReaderFormatNames();plz reply to this asap,
    regards
    sasi

    Sasi9 wrote:
    String st = "C:\Documents and Settings\Sasi\Desktop\sasi.jpg"    
    File infile = new File(st);
    //BufferedImage im = ImageIO.read(infile);
    //String[] reader_names = ImageIO.getReaderFormatNames();
    byte[] buffer = new byte[infile.length()];Now use a RandomAccessFile to read the file into your byte array. [readFully(buffer);|http://java.sun.com/j2se/1.4.2/docs/api/java/io/RandomAccessFile.html]

  • With iPhoto '11, can I access an actual jpg image from somewhere?

    I want to be able to make sure I can backup the actual, original, jpg image that is imported into iPhoto. Is there anyway to do this? Or how do I find the folder which contains the actual jpg files of the images I import into iPhoto?
    I am concerned with the possibility of iPhoto possibly crashing and not being able to open any of my images, but I would feel much safer knowing where all my images were located, so if I could find the folder in which the jpg is saved when it's imported into iPhoto, I could make sure that folder is included in my backup.
    I don't want to edit the image outside of iPhoto, I just want to make sure I can backup the actual jpg images.
    Please help!
    Thanks!

    I want to be able to make sure I can backup the actual, original, jpg image that is imported into iPhoto. Is there anyway to do this?
    File -> Export and in the resulting dialogue set the Kind to Original
    Export to your preferred location. Apps like iPhoto2Disk or PhotoShare will help you export to a Folder tree matching your Events.
    You cannot access the Library from the Finder, nor should you. The iPhoto Library Folder is a Package File. This is simply a folder that looks like a file in the Finder. The change was made to the format of the iPhoto library because many users were inadvertently corrupting their library by browsing through it with other software or making changes in it themselves.
    To see inside: Go to your Pictures Folder and find the iPhoto Library there. Right (or Control-) Click on the icon and select 'Show Package Contents'. A finder window will open with the Library exposed.
    Standard Warning: Don't change anything in the iPhoto Library Folder via the Finder or any other application. iPhoto depends on the structure as well as the contents of this folder. Moving things, renaming things,, deleting them or otherwise making changes will prevent iPhoto from working and could even cause you to damage or lose your photos.
    In iPhoto 11 the originals are stored in the Masters Folder.

  • Retrieve lost images from thumbnails?

    Hi there,
    I have a number of referenced images in my library, the originals of which were held on CD. Unfortunately the CD is no longer readable, and my originals have gone.
    I have my preview quality set to high, and Im wondering if there is any way to retreive the images from the librarys previews. I know they wont be the best quality, but it would be better than having lost the images completely.
    Ive had a trawl through the Library package, and can see the preview files that would be suitable for restoration, problem is there is about 250 images!
    Is there a smart way to retrieve these or am I going to have to trawl through every directory and copy the preview file out and re-import it?
    Any help most gratefully received!
    Andy

    You could apply the method decribed here to find the previews and duplicate and copy them to a new location.
    http://www.bagelturf.com/files/f2152c171c89f2ce02166f0f69bdac17-993.html

  • Ok. Add me to the moron list. I guess I am an over zealous trash emptier. Can I retrieve those images from the vastness by entering my time machine and restore the library from a previous date (when I wasn't a moron?)

    Ok. Add me to the moron list. I guess I am an over zealous trash emptier. Can I retrieve those images by entering my time machine and restoring the Iphoto library from a previous date (when I wasn't a moron?)

    Masters is where you want to be. They'll be in there in folders based on the date and time they were imported.
    Regards
    TD

Maybe you are looking for

  • Change  GL account for valuation classes

    This is vasanth . my client has different 5 plants  . he wants to change gl account for valuation class.because the reason is  (rawmaterial of steel&cement is being stored in spares and stores). The g/l account is 23010001 . This gl account has been

  • Having trouble restoring old files from an external Time Machine back-up to a new internal hard drive...HELP!

    O.k. So my main hard drive died on my iMac and I had to replace it. I have my old system backed up on my external with Time Machine. How do I access it to get my old files back on my new hard drive? I have read multiple forums and I have yet to find

  • Can't burn my iPhoto Library in iPhoto 6

    The last time I burned my library, was in iPhoto 5. Now, immediately after upgrading to iPhoto 6, I wanted to make a copy of the complete library from within iPhoto, but I get an error message. It prepares to burn, then immediately says finishing bur

  • Can't get wake on lan to work on Hp n40l microserver

    Hello I installed arch on my HP proliant microserver and I can not get Wake on lan to work. I tested my device with ethtool and it supports and is enabled for WOL with g value set for both. But whenever I power it off by systemctl poweroff I can no l

  • EREC: "Assign Values to Interface Parameters" query

    Hi All, I am currently on ehp4, sp4. I had a requirement to change the format of the form to display the posting. Hence i took the help of the node: technical settings>User Interfaces>Administrator and Recruiter>General Settings>Assign Values to Inte