Pdf in new window

Hi ,
i have read PDF from DB and set
response.setContentType("application/pdf");
response.setContentLength(bytes.length);
in action class of struts.
I have one success page .Once the request is processed , pdf gets open. but in same window. Please suggest me how to open the generated PDF type in new window.

It's too late to open a new window once the request is processed. You can open a new window from the html that links to the pdf by setting the href target to _blank. JavaScript can also open new windows.                                                                                                                                                                                                                                                                                                                                                                                                                       

Similar Messages

  • How can I open a blob (PDF) in new window.

    The BLOB (PDF) that is in the database is being displayed by a column link. Since the field is a blob link I haven't found any way to open it in it's separate window. There have been several postings where others have asked this but I've yet found one that has an answer.

    Hi
    I do not think it matters whether your reports portlet is a default one or a customize one. I think whne you place the portlet, you can specify in the property to open up the result in new window. I think it is common feature of Portal.
    Thanks
    Rohit

  • Open link (PDF) in new window from WebHelp custom skin button

    This question relates to my work with FM>RH integration. But the task I'm trying to accomplish is something specifically done in RH with customization of WebHelp skins, so I'm posting in this forum. I'm running RH9 on Windows XP Pro.
    We have recently replaced WebWorks with RH and finally have the mapping files set up to generate Help from our FM source files. Celebration was short, because then we realized that our users wanted a PDF option. We haven't done any mapping to create PDFs from RH, and that seems kind of silly anyway, since we have superior PDF generation from the FM files.
    So I set about making a custom button in the header of a WebHelp skin that will link to a PDF. I accomplshed that work, but its behavior falls short of the functionality I'd like to see. Currently, you click on the button and it opens the PDF in the browser window of the Help system. I want it to open in a new window, so I can keep the experience clean for the users, separating Help and PDF. I don't know if this is possible.
    Here is where I am at. To create button I navigated to:
    Project Set-up/Skins/NEW SKIN/WebHelp Skin Editor/ Main/NEW BUTTON
    When I choose the edit icon to customize the new button, there is an option to choose Link or JavaScript. I got the PDF to open inside the Help browser by just using the Link option and specifying the PDF. I have tried to use the JavaScript option without success. My JS may be wrong, but when I choose inline JS option and place anything there, it turns all the navigation buttons to gobbledy ****. Specifying an external JS file doesn't work at all.
    Any direction or help would be appreciated.
    Thanks,
    Douglas

    I see one other shortcoming with this solution now that I've implemented it. Our Help follows the applictions through a convoluted path of development servers, amongst other strangeness with the way we deploy Help and PDF documentation. My concern is referencing a single URL/file on a server. Since we're moving things around, that doesn't really work well, we want the PDF to be with the Help system, if possible. Is there a way to reference the PDF as a relative link in the baggage files, so it will pull it from whatever server the Help system resides on without having to make changes?
    UPDATE:
    It seems if you place the PDF in the WebHelp folder and reference it as the JavaScript, the Help system automatically reats it as root folder and find it there. So, I think this is the solution to my question? However, this is a bit annoying, as it means you have to remember to manually place the file in the compiled Help system. I had earlier experimented with placing the PDF as a baggage file, but those don't seem to carry over when you compile Help. Is there any way to put the PDF in the Baggage Files and designate that it be included in compiled Help?

  • Open PDF In New Window

    I have created an interactive pdf in Indesign.  It contains hyperlinks to destinations in a second pdf file.  I would like the hyperlinks to open the second pdf file in a new window.  Is there a way to do this either in Indesign or Adobe Professional?  Thank you for your help.

    Check the Acrobat forum. Someone there might be able to help out.
    Bob

  • Opening PDF in new window

    Hi all
    We want to generate a pdf at runtime in new window on click of a button suppose 'Show PDF'. We have written following code using MVC module.
    In HANDLE_EVENT for the button we are calling a controller method say 'Preview_PDF' which is generating a pdf and it opens in a new window too.
    But at the same time we are getting blank screen or view from where the event is triggered. I want the parent view should remain undisturbed and pdf should open in new window. Please advice where am I going wrong.
    Code written is as follows
    this is a controller method
    method PREVIEW_OFFER_LETTER.
    DATA: cparam TYPE ssfctrlop,
          outop TYPE ssfcompop,
          fm_name TYPE rs38l_fnam,
          my_tabix TYPE sy-tabix,
          file_size TYPE i,
          bin_filesize TYPE i,
          l_pdf_xstring  type xstring,
          lt_lines       type table of tline,
          ls_line        type tline,
          l_pdf_len      type i,
          tab_otf_data TYPE ssfcrescl,
          tab_otf_final TYPE TABLE OF itcoo .
      outop-tdprinter = 'PDF1'.
      cparam-no_dialog  = 'X' .
      cparam-preview = space.
      cparam-getotf = 'X'.
    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
    EXPORTING
      formname = 'ZHRERF_OFFER'
    VARIANT = ' '
    DIRECT_CALL = ' '
      IMPORTING
      fm_name = fm_name
    EXCEPTIONS
      no_form = 1
      no_function_module = 2
      OTHERS = 3.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CALL FUNCTION fm_name
    EXPORTING
    ARCHIVE_INDEX =
    ARCHIVE_INDEX_TAB =
    ARCHIVE_PARAMETERS =
      control_parameters = cparam
    MAIL_APPL_OBJ =
    MAIL_RECIPIENT =
    MAIL_SENDER =
      output_options = outop
      user_settings = space
    IMPORTING
    DOCUMENT_OUTPUT_INFO =
      job_output_info = tab_otf_data
    JOB_OUTPUT_OPTIONS =
    *TABLES
    *it_tab = itab[]
    EXCEPTIONS
      formatting_error = 1
      internal_error = 2
      send_error = 3
      user_canceled = 4
      OTHERS = 5.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    *********appending the otf data into the final table*********************
    tab_otf_final[] = tab_otf_data-otfdata[].
    converting OTF data into pdf data**************************
    data : it_OTF type table of ITCOO.
    it_OTF[] = tab_otf_final[].
    CALL FUNCTION 'CONVERT_OTF'
    EXPORTING
       FORMAT                      = 'PDF'
      MAX_LINEWIDTH               = 132
      ARCHIVE_INDEX               = ' '
      COPYNUMBER                  = 0
      ASCII_BIDI_VIS2LOG          = ' '
      PDF_DELETE_OTFTAB           = ' '
    IMPORTING
       BIN_FILESIZE                = l_pdf_len
       BIN_FILE                    = l_pdf_xstring
      TABLES
        OTF                         = it_OTF
        LINES                       = lt_lines
    EXCEPTIONS
       ERR_MAX_LINEWIDTH           = 1
       ERR_FORMAT                  = 2
       ERR_CONV_NOT_POSSIBLE       = 3
       ERR_BAD_OTF                 = 4
       OTHERS                      = 5
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
      l_pdf_len = xstrlen( l_pdf_xstring ).
      data: cached_response type ref to if_http_response.
      create object cached_response type cl_http_response exporting add_c_msg = 1.
      response->set_data( data   = l_pdf_xstring
                            length = l_pdf_len ).
      cached_response->set_header_field( name  = if_http_header_fields=>content_type
                                  value = 'application/pdf' ).
      cached_response->set_status( code = 200 reason = 'OK' ).
      cached_response->server_cache_expire_rel( expires_rel = 10 ).
      data: guid type guid_32,
            display_url TYPE STRING,
            value type string,
            extension type string.
            extension = 'pdf'.
      concatenate 'attachment; filename='
                        runtime->application_name
                        extension
                        into value.
      cached_response->set_header_field( name  = 'Content-Disposition'
                                  value = value ).
      CALL FUNCTION 'GUID_CREATE'
          IMPORTING
            ev_guid_32 = guid.
      CONCATENATE runtime->application_url '/' guid '.pdf' INTO display_url.
      cl_http_server=>server_cache_upload( url      = display_url
                                             response =    cached_response ).
      NAVIGATION->RESPONSE_COMPLETE( ).
    endmethod.
    Please advice

    Capture the generated url for the PDF document into a variable w_url and then use the client click event of the button SHOW PDF to open it in a separate window.
    something like this
    <htmlb:button id="btn1" onClientClick="window.open(w_url)"
    this should open your pdf in a new window.
    hope this helps.
    Cheers

  • Button on Click, loads a pdf in new window

    Hello, I am trying find the correct as3 code to make a button on Click, open a pdf in a new window. I have tried different ways, but when I add the code not only does it give me errors, but it makes my swf flip through all the pages instead of stopping on load. It is fine before I enter the code for this button.
    Just to let you know, this button is within a movie clip on the main stage. I really wanted it in a MC within another MC, but can't figure out where to put the code.
    Should it go on the main timeline, where all the rest of the code is, or should it go within the MC?
    Please help! Very frustrated with AS3.
    Thanks!

    This is all my code. At this point my MC moves through all my content pages. Before I entered the last code (last 3 lines) it worked fine. I'm sure I am missing something simple. With the last piece of code it also gave me the error "1120:access of undefined property TNT_pricelist09. I would imagine because I have to add the folder name to the file name?
    Thanks for your help!
    home_btn.addEventListener(MouseEvent.CLICK, homePage);
    pricing_btn.addEventListener(MouseEvent.CLICK, pricingPage);
    about_btn.addEventListener(MouseEvent.CLICK, aboutPage);
    contact_btn.addEventListener(MouseEvent.CLICK, contactPage);
    function homePage(e:MouseEvent):void
    content_mc.gotoAndPlay("home");
    function pricingPage(e:MouseEvent):void
    content_mc.gotoAndPlay("pricing");
    function aboutPage(e:MouseEvent):void
    content_mc.gotoAndPlay("about");
    function galleryPage(e:MouseEvent):void
    content_mc.gotoAndPlay("gallery");
    function contactPage(e:MouseEvent):void
    content_mc.gotoAndPlay("contact");
    content_mc.pricePDF_btn.addEventListener(MouseEvent.CLICK, openPDF);
    function openPDF(e:MouseEvent):void
    navigateToURL(URLRequest(TNT_pricelist09.pdf));

  • Open pdf in new window from an iframe

    i have a web page with an iframe that displays pdf's chosen  from a drop down menu.
    i need to be able to make the current pdf open from the iframe into a new window.
    any ideas?
    thanks
    Larry

    heres an example.
    http://www.sixmanmagazine.com/cev test/CEV00152/CEV00152.html
    i uploaded that so you can see what i am trying to do.
    the left side is for video and the right side is the iframe.
    i want the content of the iframe that i want to display in a new window.
    Thanks for your time.
    larry

  • Open PDF in new window to bookmark

    Is it possible to open a PDF in a new window to a bookmark? I tried the code below; the PDF opens in a new window but does not open to the 3rd page. Appears that "page=3" is getting removed from the URL when opening. Any ideas?
    <af:goLink text="View PDF" id="gl1"
                                 targetFrame="_blank"
                                 destination="SMWebLogicAgent_conf_enu.pdf#page=3"/>
    JDeveloper 11.1.1.7

    This offer Adobe doc http://partners.adobe.com/public/developer/en/acrobat/PDFOpenParameters.pdf States that you can use '&'  instead of the '#'.
    Timo

  • PDF in new Window works only once?

    Hello,
    I have a problem showing a PDF in a new window. I get my PDF created from a BAPI as a byte[] - works fine. To show the PDF I use the follwong code in an action of a button:
    byte[] pdfContent = wdContext.currentContextElement().getPdfDokument();
    try {
      IWDWebResource pdfResource = WDWebResource.getWebResource
        (pdfContent, WDWebResourceType.PDF);
      wdComponentAPI.getWindowManager().createExternalWindow(
        pdfResource.getURL(),"Title",
        false).open();
    } catch (WDURLException e) {
      e.printStackTrace();
    It works fine - but just the <b>first time</b> I press the button. Window is opened and inside Acrobat Reader openes with my PDF.
    I close that and press button again. Window openes but no PDF anymore?! Any hints?
    Best regards,
    Frank

    Hi,
    I have a problem. I'm trying to display a smartform from a webdynpro application, but when I try to write:
    IWDWebResource pdfResource = WDWebResource.getWebResource
        (pdfContent, WDWebResourceType.PDF);
      wdComponentAPI.getWindowManager().createExternalWindow(
        pdfResource.getURL(),"Title",true).open();
    the program does not recognize the pdfResource variable. It says that it cannot resolve it.
    Any hints?
    Thanks.
    Jesus

  • Converting Word Hyperlinks to PDF as "New Window"

    I have a user who has a Word 2003 document which has a lot of hyperlinks.  In Word, the "Target Frame" setting associated with the hyperlinks is set to "New Window".  We use Adobe PDFMaker to convert the Word document to a PDF.  The hyperlinks convert into the PDF file, however when you click on the link, it opens in the same window.  How do we get it to open in a new window, so that the original PDF file as well as the linked PDF file are both open?

    To expand on what DevyaniB said. This is an application preference, not a document preference. You can set this preference for your computer, not on another user's computer.

  • JavaScript needed - open PDF in new window

    I'm creating an interactive PDF in InDesign CS5.
    This PDF contains a button I've made that links to another, separate, PDF file.
    This is all working fine - trouble is, when I click the button to open the second PDF file, the first PDF automatically closes.
    Is there any way to make the second PDF open in a new window, keeping the first PDF open?
    I've been told I need to add a JavaScript in Acrobat.
    Your help would be much appreciated!

    Thanks - we're definately heading in the right direction now!
    I'm not sure how to select "Open in: New Window" as specified.
    In the button properties, there doesn't seem to be this sort of option (see image below).
    Perhaps I'm looking in the wrong place?
    Also, I believe the link action is a "Open a file" type.

  • Pdf in new window full width and height

    Hi i managed to create a new window and add a pdf to it :
    var pdf = new air.HTMLLoader();
    pdf.height = 600;
    pdf.width = 400;
    pdf.load(request);
    mywin = window.open("",
    "pdfWindow","height=600,width=400,top=10,left=10");
    mywin.nativeWindow.stage.addChild(pdf)
    But i would like to make the pdf scale to the width and
    height of the window , i tried width = '100%' but then it doesn't
    show a pdf
    for the current result see :
    Screen

    Okay i created a test :
    var pdf = new air.HTMLLoader();
    pdf.height = 600;
    pdf.width = 400;
    pdf.load(request);
    mywin = window.open("",
    "pdfWindow","height=700,width=500,top=10,left=10");
    mywin.nativeWindow.stage.addChild(pdf)
    pdf.width = mywin.nativeWindow.stage.stageWidth
    pdf.height = mywin.nativeWindow.stage.stageheight
    But then the pdf doesn't show, i also think this wouldn't
    work on resize of the window ?
    Or is there a event that is triggered

  • Show Pdf in new window

    Hello,
    Is there a way to show a pdf (I already have the the byte[] for the document) in a new window or prompt the user for download when entering on a taskflow.
    We already have it working using on a button with af:fileDownloadActionListener but we need a solution, if possible, when entering on a taskflow.
    We are working with ADF 11g with Jdeveloper 11.1.1.4.0.
    Regards,
    Danilo

    Re: Creation of PDF Document  using ADF Table data in new window

  • When clicking on PDF link new windows opens then closes

    Okay I have IE 7.0 and Reader 9.0. I am running a Breeze file and within the file there are links to PDF's, so the problem is when I click on the link the PDF seems to open in a new web tab but then suddenly disappears. I have co-workers with the same configuration and it works for them but then for others its the same error. Anyone have any idea as to what is going on? What is the soluton? Or where can I go to find it? Thanks.

    This should help:
    1. Go to: Tools > Options > Tabs
    2. There is a section at the top that says 'Open links that open in a new window in:' and then a drop-down menu
    3. In the drop-down menu, select the 'Current Tab' Option
    4. Click 'OK'
    '''If this was the answer you were looking for, please click 'Solved' -- Thanks.'''

  • Open Google clicks and PDFs in New Window

    When I Google something, then click on links, the links open in the same screen, and not in a new window.  This makes it hard to navigate backwards.
    Also, when I click on PDF link, the link opens in the browser window, and again, I lose the website that I was on.
    Is there a setting on my Mac that can open stuff in a new window?  I tried the Finder General command "open in a new window" but that did not help.
    JoAnn

    Hi,
    I'm using Safari and FireFox -- mostly Safari.
    I looked in Safari preferences, and can't tell what to change.  It says "New windows open with Homepage".  Do I change to "Empty Page"??  Also, I looked at FireFox preferences, but can't see what to change.
    Love your pic
    JoAnn

Maybe you are looking for

  • Odd, Green video in Adobe Premiere CS4?

    Hi! This has been happening to me a lot lately, and I really need a fix! When editing my projects, I will have imported a lot of video files. Before dragging those files into my timeline, I like to preview them. However, sometimes, the video does not

  • Share all calendars in iCal thru iCloud

    I have been trying to get all the calendars to share between my wife and myself.We are using her calendar and she is inviting me to join which I was able to do with one of them (home) but the others are not inviting. On the home calendar we have it s

  • Iphoto book - problem with deleting extra pages

    I am finishing up a book with iphoto of 85 pages of photos.  I want to delete 6 empty pages, but when I go to All Pages View, hold control key and click, the only option is to add pages.  I don't want to purchase book and assume apple won't charge/pr

  • Creating database Manually

    Dear Experts I want to create database in oracle 10g manually, without using dbca or create database script on sql. I have been searching google, but not getting any related document. Can you please guide me or provide any link where I get steps to c

  • SQL Management Studio Installation Problems

    My hard drive crash and I'm forced to use Windows 8 on my laptop for a while. Visual Studio 2012 installed okay but I cannot get the SQL Management Studio to install. I have SQL Management Studio 2005 CD's and I've also tried to download and install