Display jpg file using ADF Application!!!!!!!!!!!

Hi All,
I am opeing a .tif image file kept at a remote location using HttpServletResponse object:
response.setContentType("application/x");
response.setHeader("Content-Disposition", "inline; filename=\""+fileName+"\"");
once this has been done, InputStream(the input stream of the file obtained using new FileInputStream(fileobj)) is piped into an OutputStream using some function.
using this function the .tif file gets opened in MS picture viewer, but only one file(not like when files are viewed on local machine where all differnent jpg's are viewed using the next button).
Now what client wants is when there are multiple files kept at the location, all of them should be accessible using next button of the MS picture viewer.
It is possible to do so?
Any help???

ok, i agree with that and was trying for the same. i.e was taking array of InputStream[] , OutputStream[] and ByteArrayOutputStream[]. Write input streams into ByteArrayOutputStreamOBJ, write this ByteArrayOutputStreamObj to OutputStreamobj(ByteArrayOutputStreamObj .writeTo(OutputStreamobj[i]);).
This method when run in loop runs for the third time throws an exception that connection was closed by remote host.
Any Suggestions ????

Similar Messages

  • Problem displaying tiff files using ADF

    Hi,
    I have some TIFF files in a table - IMAGE_TABLE
    ID NOT NULL NUMBER
    DESCRIPTION VARCHAR2(40)
    IMAGE ORDSYS.ORDIMAGE
    I am unable to display TIFF images in an ADF form. I can use processCopy to convert the TIFF images to jpeg, which them display correctly. All other JPEG or GIF display correctly, it's only the TIFF that don't. I've tried variours tiff files (different sources, converted gif and jpeg to tiff) but none display correctly (i.e. in IE you get the red 'x' - in firefox you get the broken picture symbol or nothing)?
    This appears to be an ADF issue as I 'can' dsiplay the TIFF files correctly in IE and firefox using the quicktime plugin but not from an ADF form using JDdevloper? (The code/application is Steve Muench's JSFOrdImageExample - http://otn.oracle.com/products/jdev/tips/muench/jsfordimage/JSFOrdImageExample.zip)
    Any ideas or suggestion would be appreciated.
    Thanks.
    JDeveloper 10.1.3 build 10.1.3.0.4
    DB is 10gr2

    Hi,
    yes, I can view tiff's in browsers (IE and firefox) using the quicktime plugin. I've selected quicktime as the player in the af:objectmedia property settings and Autostart = true, but using the ADF form from JDeveloper will not display tiff images (jpg's, giff's etc. are fine) even though the browser will display tiff's on it's own?
    Thanks.

  • How to build ear files for ADF application using Ant task

    How to build ear files for ADF applications using Ant. The ojdeploy ant task can not find application-level deployment profiles. I am trying to automated build and release for ADF application.
    Any help is highly appreciated.
    Thanks
    Shiva

    Hi Timo
    Thanks for your reply.
    I have successfully created ear file using ojdeploy on jenkins. however when am trying to auto deploy using WLDeploy ant task am getting the following
    error :
    weblogic.application.ModuleException: :oracle.mds.config.MDSConfigurationException:MDS-01335: namespace "/oracle/webcenter/quicklinks/scopedMD" mapped to metadata-store-usage "WebCenterFileMetadataStore" but its definition was not found in MDS configuration
    Please advise how to handle this.
    As am a newbie to ADF, could you please advise if it is possible for the ADF application deployments can be automated for different environments using jenkins due to this MDS dependencies.
    Appreciate your help.
    Thanks
    Shiva

  • How to display flash file in adf pages

    how to display flash file in adf pages need help

    Thanks all,
    It is resolved.
    the code i am using to display a flash is below.
    <f:verbatim>
    <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
    codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version
    =10,0,0,0" width="300" height="300" id="11gR1_aniH_grey" align="middle">
    <param name="allowScriptAccess" value="sameDomain" />
    <param name="allowFullScreen" value="false" />
    <param name="wmode" value="transparent" />
    <param name="movie" value="mx2004demo.swf" />
    <param name="quality" value="high" />
    <param name="bgcolor" value="#4d5c64" />     
    <embed src="../Images/mx2004demo.swf" quality="high" width="300" height="300" name="mx2004demo.swf" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false"
    type="application/x-shockwave-flash" wmode="transparent"
    pluginspage="http://www.adobe.com/go/getflashplayer" />
         </object>
    </f:verbatim>

  • Bordercontainer into .jpg file using php

    hi
    i have done one bordercontaine using flex 4.
    that bordercontainer contain one image and label
    i want to store that bordercontainer into jpg using php file
    I give my mxml file and php
    newflexphp.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
                   xmlns:s="library://ns.adobe.com/flex/spark"
                   xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600">
        <fx:Declarations>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
        <fx:Script>
            <![CDATA[
                import mx.controls.Alert;
                import mx.graphics.codec.JPEGEncoder;
                import mx.rpc.events.ResultEvent;
                import mx.utils.Base64Encoder;
                //import com.adobe.images.JPGEncoder;           
                import flash.utils.ByteArray;
                import flash.system.System;
                private var bmSave:BitmapData;
                public function resultHandler( event: ResultEvent ):void
                    Alert.show( "Result "+String(event.result) );
                public function saveImg():void{
                    var jpgSource:BitmapData = new BitmapData (bcont.width, bcont.height);
                    jpgSource.draw(bcont);
                    var jpgEncoder:JPEGEncoder = new JPEGEncoder(85);
                    var jpgStream:ByteArray = jpgEncoder.encode(jpgSource);
                    var header:URLRequestHeader = new URLRequestHeader("Content-type", "application/octet-stream");
                    var jpgURLRequest:URLRequest = new URLRequest("http://localhost/jpg_encoder.php?name=sketch1.jpg");
                    jpgURLRequest.requestHeaders.push(header);
                    jpgURLRequest.method = URLRequestMethod.POST;
                    jpgURLRequest.data = jpgStream;
                    navigateToURL(jpgURLRequest);
            ]]>
        </fx:Script>
        <s:BorderContainer x="369" y="171" width="232" height="216" id="bcont">
            <mx:Image x="44" y="14" width="151" height="87" source="images/3.jpg"/>
            <s:Label x="44" y="132" text="Best wishes" width="94" height="44"/>
        </s:BorderContainer>
        <s:Button x="163" y="182" label="Button" click="saveImg()"/>
    </s:Application>
    jpg_encoder.php
    <?php
    if (isset($GLOBALS["HTTP_RAW_POST_DATA"]))
        // get bytearray
        $jpg = $GLOBALS["HTTP_RAW_POST_DATA"];
        // add headers for download dialog-box
        header('Content-Type: image/jpeg');
        header("Content-Disposition: attachment; filename=".$_GET['name']);
        echo $jpg;
    ?>
    now i get the result seketch.jpg file
    but the link is redircted to php
    just i want to convert my bordercontainer into .jpg file using php.
    how can i do .
    regards
    athi

    Try this possible workaround:
    1.— Take your original file (before any edits) and duplicate it.
    2.— Work on the duplicate (exact clone) only.  Do all your Photoshop edits to your heart's content.  (Optional step: save the file, but don't close it so you don't compress the JPEG and deteriorate its quality.)  Do a select all (Command+A on the Mac, Control+A on Windows) to select the entire pixel content of the duplicate, and COPY that.  Now you have your edited image on your clipboard.
    3.— Open the original file, and do a select all on it, but don't copy that!  Instead, DELETE all the pixel content of the original.  Now you have a blank image with only the metadata of the original.
    4.— Paste the contents of your clipboard (the pixels of the edited clone) into the blank original.  Save.
    With any luck, you'll have the edited pixels with the metadata of the original.
    It should work, but there are no guarantees.

  • Displaying blob image using adf

    Hi ,
    We are using adf in our application. We have to disaply blob image from oracle data base on the adf jspx page.This jspx page consists of 2 jsff files.
    I have created an httpservlet and called on the source parameter of image this httpservlet with binding similar as below:
    source="/httpServletName?id=#{bindings}}"
    I am able to display the image.
    But my concern is that I am using iterator for displaying images as there can be multiple records in the table but for every recoed I am getting same image. Please suggest how can I display multiple images coming with respect to various records of data base.
    thanks & Regards

    Hi,
    After attempting the solution given above also I am getting the same issue.
    On the jspx page I want to show Imageid, imagedescription and photo .
    I have 4 records coming from database on the jspx page. I have found that all the data (imageid, description) is first displayed on the jspx and then control gets transferred on the ImageServlet only once and in request.getParameterMap() I get only one "ID" value i.e. the ID value of last record (4th record) coming from data base and hence in all the 4 records on jspx I am getting the same image (i.e. the image in the 4th record of db). Please help me to proceed on this issue.
    On jspx, I have given image source value as :
    <af:image shortDesc="image"
    id="image1"
    source="/imageservlet?id=#{bindings.Id.inputValue}}"/>
    Thanks

  • How to display HTML files using ABAP Webdynpro?

    Hi,
    I have a html index file and a bunch of other files accessed by the index file  in a specific directory on the SAP server. I'd like to display the index file via ABAP webdynpro and allow the users to click on what they need to see. How can I achieve this using utilizing the ABAP webdynpro technology ?
    Thanks!

    Hi Thomas,
    Thanks for taking the time to answer my question.
    I have the main html file and all other files needed by the main file in one directory on the application layer of SAP. I'd like to provide the user with a link, by clicking on which they should be able to get to the main html file using the browser. This is just a standalone application.
    I can try the approach using BSPs, however, I'm new to that area. Could you point me in the right direction to get started?

  • Error in displaying PDF file in webdynpro application

    Hi Experts,
    I am trying to display one pdf file using webdynpro abap using MIME.
    While executing the application i am getting an error in the browser:
    " File doesnot begin with '%PDF-' "
    Please help me to proceed.
    Regards,
    Arun.

    Hi Arun,
    Please check this...
    File does not begin with %PDF
    File does not begin with %PDF
    Cheers,
    Kris.

  • Displaying Master-Data using ADF DI

    Hi
    I'm trying to display a master data(as a form) and a detail data(as a table) in excel sheet using ADF DI.
    The process I followed is as below.
    1. This is on HR schema. I created a departmentsVO, and dragged Departments from the data control to the top half of a jspx page as a form, and Employees datacontrol that is wihtin the Departments datacontrol into the lower half of the page.
    2. I ran the page, and the master-detail is perfect i.e., when i click navigate the departments form, corresponding employees of that department are coming in a table in the lower half.
    But the problem is when i used this pagedef file to use in an excel file.
    1. Alll form elements are available in the excel as individual components. Table is available as a tree component.
    2. I binded all the form elements in the excel, also bound prev and next buttons, all at the top section of the excel file.
    3. Binded the table component in the bottom of the excel file.
    3. Defined table download action and Worksheet downsync action as worksheet properties. Workbook prop are also defined properly.
    When I ran the page,
    Form elements and table is prefilled, navigation of form is also working fine. But when I navigate through the form, the corresponding employees are not changing, they are all employees of the first department id.
    My requirement is to change the employee table as the department form is being navigated.
    Can someone pls give some suggestions. What i think I may be missing is that the table is not getting refreshed as I navigate the form(But I already associated the table download action to the worksheet properties).
    Thanks in advance,
    Ravi.

    Found a solution. This might be helpful to others...so m posting it :-)
    While binding the 'Next' button, I added 'Download' component action of the table to the actionset of the button(which already has UpSycn, Next, DownSync).
    So, on click on the button, it actually downloads the latest data to the table. And master - details were shown just perfectly :-)

  • What is the problem when opening jpg files using Desktop API

    Hi, i would like to open jpg, or gif files using Desktop API, and the application crashes.The Desktop API is supported by my OS, because txt files, or file directories can be opened, mails can be sent, browsing is also supported.
    Only jpg and gif, and i think other picture formats cannot be opened.
    Obviously ACDSee and other picture viewing programs are installed in my computer.
    The corresponding application code can be found at the bottom of the page of http://www.awprofessional.com/articles/article.asp?p=661371&seqNum=2&rl=1
    my code:
    if(Desktop.isDesktopSupported()){
    Desktop desktop=Desktop.getDesktop();
    try
    desktop.open (fileToOpen);
    catch (IOException ioe)
    JOptionPane.showMessageDialog (frame,
    "I/O problem");
    catch (IllegalArgumentException iae)
    JOptionPane.showMessageDialog (frame,
    "File doesn�t exist");
    fileToOpen is obviously a File.
    Thx for the help in advance.
    Message was edited by:
    javahelps
    Message was edited by:
    javahelps
    Message was edited by:
    javahelps
    Message was edited by:
    javahelps

    My file association for jpg files is correct, if i click on a
    jpg, ACDSee starts immediately.Although I am a long time Windoze non-user, I vaguely remember that there's a difference between correct file-type association being set and some application starting at a mouse click on a file icon. I also vaguely remember Windoze file-type association mechanism uses a few action-types. Java Desktop should expect a specific action-type for the association.

  • Adding EXIF standards back into a JPG file using Photoshop

    Can anyone tell me how this is done?
    I'm trying to get photos (JPG files) I've edited in Photoshop and placed on an SD card to display on a Panasonic plasma television (TC-P42X1). The televison will only recognize JPG files with DCF or EXIF standards in tact. I'm assuming photos taken with a digital camera (unedited) already build in these stanards, as those photos view just fine. I'm also assuming that Photoshop strips the JPG file of these standards since the error I'm getting is "Cannot Read" with edited images.
    Of course Panasonic says, "It's an Adobe issue." Adobe would probably tell me "It's a Panasonic issue." Neither of those answers help solve my problem.
    Here is what I've tried so far, with little to no luck. Using Photoshop, I've opened an image, gone to File/File Info (given the photo a description), selected "OK" and saved the image as a JPG file (did not use the "Save for Web" path). This has gotten me a step closer. Now I can see a thumbnail image on the television when in menu view, but it still says, "Cannon Read" when trying to view the images with the slide show option. Does anyone know the trick is using Photoshop to correct this issue? I'm open to other options as well.
    Thank you in advance to anyone willing to help solve this problem!!!

    Try this possible workaround:
    1.— Take your original file (before any edits) and duplicate it.
    2.— Work on the duplicate (exact clone) only.  Do all your Photoshop edits to your heart's content.  (Optional step: save the file, but don't close it so you don't compress the JPEG and deteriorate its quality.)  Do a select all (Command+A on the Mac, Control+A on Windows) to select the entire pixel content of the duplicate, and COPY that.  Now you have your edited image on your clipboard.
    3.— Open the original file, and do a select all on it, but don't copy that!  Instead, DELETE all the pixel content of the original.  Now you have a blank image with only the metadata of the original.
    4.— Paste the contents of your clipboard (the pixels of the edited clone) into the blank original.  Save.
    With any luck, you'll have the edited pixels with the metadata of the original.
    It should work, but there are no guarantees.

  • .jpg files are not application files

    Lion 10.7.2 thinks the .jpg files I download are applications and issues a warning with each file. How do I disable the warning or tell Lion that .jpg is not an application?

    You need to check the cffile.ServerFileExt variable which contains the file extension to make sure it matches your set of allowed extensions. Make sure you upload into a folder outside of the webroot first (such as getTempDirectory()) to avoid some potential security issues.
    You can also use IsImageFile() in addition to the file extension test, but you should not rely on isImageFile (always check the file extensions).
    If you have CF10 you can use <cffile accept="*.jpg,*.png" strict="false" ...>  as well.
    In short - don't rely on the mime type for anything it can be spoofed by a hacker to upload malicious files, always check the file extension (worth repeating).
    -- Pete Freitag
    Foundeo Inc - Makers of HackMyCF & FuseGuard

  • Displaying JPG's in standalone-applications

    Hy all!
    Does somebody know where I need to save a JPG so that a standalone-application can load it?
    I always get a NullPointerException when executing the following code:
    public SpaceBallFrame() {
    Graphics g = getGraphics();
    Image gameOverPic = Toolkit.getDefaultToolkit ().getImage("gameover.jpg");
    boolean b = g.drawImage(gameOverPic,50,100,this);
    I tried all folders which made sense but it didn't work.
    Thanks for help
    Boni

    Does somebody know where I need to save a JPG so that a standalone-application can load it?By using the following:
    Image gameOverPic = Toolkit.getDefaultToolkit ().getImage("gameover.jpg");
    The program assumes that the JPG file is in the same directory as your class file.
    The reason your program doesn't work is probably because drawing an image is usually done in a paint method. Try something like this (where the gameOverPic is defined as a globally accessible object):
    Image gameOverPic;
    public SpaceBallFrame() {
    gameOverPic = Toolkit.getDefaultToolkit ().getImage("gameover.jpg");
    public void paint(Graphics g) {
    g.drawImage(gameOverPic,50,100,this);
    V.V.

  • How to use  ADF application functionality in Webcenter Portal

    Hi,
    We have an separate ADF application with bunch of functionality that are been using in others applications.We have to use these functionality in the WebCenter portal.
    In this ADF application, each jspx page used for implementing different functionality(for example Calendar for one page, subscriptions for one page like that) and there are no bounded task flow used.
    Challenge here is, need to some how import the ADF application as reusable component (section) and yet to use different functionality (I mean accessing each jspx page)
    So, what are the ways we can utilize these ADF functionality in WebCenter portal? Let me know your thoughts?
    Any help really appreciated.
    Thanks,
    San.

    All,
    if you have WebCenter in place the best way is to use the ADF portlet bridge. You can create portlet entries at design time in JDev on each JSPX as well as on any TaskFlow definition (right click as mentioned above). That's quite convenient if you stay in the WebCenter / ADF world. You'll get the standalone as well as the portletized application so the standalone version will still be working. Mind that if you portletize an ADF Application you need to deploy it in a portlet runtime. That means you need to extend your ADF container with the portlet runtime. That requires a WebCenter license for the server since the portlet runtime is a part of the WebCenter product stack.
    In respect of SSO, after deploying your Portlet Producer App you'll get WSRP Webservices on application level for which you can apply OWSM policies (Enterprise Manager) so the identity of the portal will be propagated to the Portlet Producer App. Details can be found on WebCenter Portal Developer's Guide.
    Just to let you know that these portlets can be only consumed on Oracle's portals (be that WebCenter or Oracle Portal 11g). That's caused by some Oracle specific WSRP additions to the ADFPortlet Bridge.
    Jiri, what do you mean with "enhance it with portal features"? Oracle's portlet aproach is fully based on WSRP, means decoupling. So you cannot add portal features to the portlet. Everything has to be packed in request and response. There's no direct access to portal /portlet resources to interact with.

  • Displaying PDF file in Flex application

    Hello,
    Is there any way, by which I can read/display PDF file as it is in Flex application (Web based). Is there any way or work around by which I can achieve
    this.
    Awaiting for prompt response.
    Thanks and Regards

    Hello Mariush,
    I have to display the content of the PDF in the flex application. If not PDF directly, is there other workaround for this. Or can I display the content of the MS word file, if not PDF.
    Thanks and Regards
       Khalid Chaudhary

Maybe you are looking for

  • IWeb '08 will delete files from .mac. BACK UP your custom files!

    ...obliterated everything in Web/RSS and Web/Sites/iWeb. Just a word of caution if you keep roll-back versions of hand-customized HTML in there with your site files. By the same token, the new file structure & naming scheme is less hideous. Single fo

  • Connection Pool - unable to establish connection for one or more OC4J inst.

    Hi. I'm using Oracle JDeveloper 10.1.3.1 to develop some app. Database is Oracle XE 10.2.0. Application server is Oracle Aplication Server 10.1.3.1 After create a needed code, I' v tried establish Connection Pool. When I' v tested connection, next er

  • Problem of Master-Detail displaying

    I have a room VO ,in every room I have several Patients.I display the rooms in a table(room.uix) .And I want to display the patients for the selected room in another table(in patient.uix) and also the selected room. I tried it through using a event "

  • IPhoto doesn't recognize my iPhone 4s?

    I connect my iPhone 4s to my iMac to import my photos, and iPhoto shows "Apple iPhone" as a device connected. My phone is named "gPhone" and is not listed. None of my pics are available to import.

  • Help!  kids stuck cards in cd slot

    My boys stuck those stupid fake credit cards we all get in the mail into my cd rom slot. I've pulled out all that I can, but now the machine whines when it's turned on and will no longer recognize cd's. Is there any hope for the machine? (Everything