How to call jsp in PLSQL code (to upload a file in IFS)

Hello,
We develop our PORTAL (9.0.2) with PL/SQL way.
We want to make a form to upload file in IFS.
We create a form like that :
htp.formOpen(cmethod =>'post',
     cenctype => 'multipart/form-data',
     curl => '/pls/ptlcollab/ptlcollab.GestionDoc_screenbuilder.manipTableIFS',
     cattributes => 'name="ifs"') ;
htp.TableData(htf.FORMFILE(cname=>'file', cattributes => 'size="25"')) ;
The manipTableIFS procedure calls a loaded java procedure which called a servlet which work with IFS.
BUT, modplsql seems to want we directly upload the doc in a table but we want to upload the doc in iFS !!!
So, the solutiuon seems to call a jsp (or a servlet directly from our plsql code).
BUT, how could I do that ???
Any help would be greatly appreciated.
Regards.
Luc.

Something along these lines ought to do what you want:
<html>
<body>
<form name='foobar' action='foobar.jsp'>
<script language='Javascript'>
function askim() {
  if (confirm('Is you sure?')) {
    document.foobar.submit();
  } else return false;
</script>
<input type='button' value='Submit' onClick='askim()'>
</form>
</body>
</html>
Your mileage may vary.
But the idea here is that the Javascript merely submits the form if the user clicks "OK" on the confirmation pop-up. Otherwise, nothing happens. The form is submitted to a JSP file which accepts the request, does something (such as call your Java class), then prints out some HTML in response.

Similar Messages

  • How do I write a javascript code to open InDesign File, import Doc, save and export to pdf?

    How do I write a javascript code to open InDesign File, import Doc, save and export to pdf?

    Hi hasvi,
    Need Template(.indt), textframes etc for the following script:
    var myFolderInd = Folder.selectDialog();
    var myFile = myFolderInd.getFiles("*indt");
    app.open(myFile)
    var myDoc = app.activeDocument;
    var myDocName = myDoc.name;
    var mySaveFile = app.activeDocument.save(myFolderInd.fsName + "/" + myDocName.split(".indt").join(".indd"));
    var myFolderDoc = Folder.selectDialog();
    var myFile1 = myFolderDoc.getFiles("*doc");
    mySaveFile.pages[0].textFrames[0].place(File(myFile1))
    //~ mySaveFile.place(File(myFile1))
    app.activeDocument.textPreferences.smartTextReflow = true;
    var myPDFFile = new File(mySaveFile.filePath + "/" + mySaveFile.name.split(".indd").join(".pdf"))
    myDoc.exportFile(ExportFormat.PDF_TYPE, File("~/Desktop/abc.pdf"));
    alert("Process Completed")
    Regards
    Siraj

  • Code to upload a file in java

    HI friends
    I want to know how to upload a file in java.
    After submitting the selected file should be copied in a folder created by us only.
    I mean first we need to select a file using browse,then after submitting the selected file should be placed in a folder ,this
    folder should be created by us only using mkdir();
    Can any one send me the code to upload a file.
    Thanks in advance

    Install Google at your machine, note the input field and the button, enter smart keywords such as 'jsp file upload' in that input field, then hit that button and see!
    For the rest of your questions, just read the javadocs of java.io.File and javax.servlet.ServletContext.
    Oh, in the future, please ask Servlet related questions at the Servlet forum.

  • How to call jsp from another jsp

    Hi, All,
    I have several jsp files in my pagelet. I need to put a link in one jsp file. When client click the link, it will show another jsp file. Could anybody tell me how to do that?  i have tried to use following code in page1.jsp,
    IPortalComponentURI componentURI= componentRequest.createPortalComponentURI();
    componentURI.setContextName("pagelet/page2.jsp");
    String docuri = componentURI.toString();
    <body>
    click  '<a href="<%=docuri %> ">here</a>' to link to pages.
    But it does not work. Any help will be great appreciated.
    Marea
    Message was edited by:
            Marea Yang
    Message was edited by:
            Marea Yang

    HI Yang,
    You can achieve it through eventhandliling in jspdynpage.
    Go through this link ,
    i.<a href="http://help.sap.com/saphelp_nw70/helpdata/en/2e/d2a441cd47a209e10000000a155106/content.htm">eventhandling</a>.
    ii.<a href="https://forums.sdn.sap.com/thread.jspa?threadID=103335">method to call jsp</a>.
    iii.<a href="https://forums.sdn.sap.com/thread.jspa?threadID=393522">calling  resource JSP in Portal Compoent</a>
    Hope It'll help you.
    Regards ,
    Malini.V

  • How to call JSP that outputs XML without HTTP request

    It should be a simple solution but I can't seem to find a concise recommendation anywhere. We are building a B2B subsytem for our app and we need to send XML to our vendor. I'm evaluating the possibility of using JSPs for that and everything looks good until the time you actually want to invoke it. It's obvious how to code the JSP itself, but I'm looking for an efficient way to call it to generate XML. We do not have an HTTP request or a servlet, the communication is on the EJB level. So I can't get a RequestDispatcher for example, and we don�t have HttpServletRequest/HttpServletResponse either. It is NOT a servlet or JSP calling another JSP, it's a regular Java class or EJB.
    Ideally, I would rather bypass the whole HTTP infrastructure and just use JSP as a formatter. So it boils to a question of how to invoke it and how to pass the parameters without HTTP session or request. One of the alternatives we are reviewing is using XSP but we would prefer JSPs if we can figure out how to call it efficiently. HttpUrlConnection is not a good option, we'd like a direct call.
    Any suggestions will be greatly appreciated.

    Thanks for the response. Let me clarify the requirements for the question. The way we are supposed to send XML to the vendor is via CORBA (don't ask me why:-) where the only parameter essentially is a string containing the XML document. So the quesiton is not how to send it to the vendor, but how to format our JavaBeans into XML.
    We can't use JAXB because it doesn't support schema. We tried a few libraries out there but they stumble on our schema and we can't change it because it comes from the vendor. So it sounds like our only choice for today is to generate XML ourselves.
    The data is stored in JavaBean packet objects and that's our input. Our output should be a string with XML document conforming to the schema. Posting a request to ourselves will of course work, but that's too much unnecessary overhead. Another option is implementing HttpServletRequest and HttpServletResponse and calling service method directly. Better suggestions?

  • Do you know how to call RDF with java code?

    Say me a tip!
    Environment:
    Linux, Reports 6i,java beans, jsp
    My mission is to run a report with java code.
    But I don't know how to.
    Basic flow is :
    On web browser, call jsp a program and
    that jsp call a java module,
    and the java module call a reports RDF with parameters
    I don't need reponse message from rwcgi60 or rwrun60.

    hello,
    the easiest way is to use the regular HTTP request to either the servlet or the CGI to run a report request from within a java-class.
    regards,
    the oracle reports team --pw                                                                                                                                                                                                                                                                                                                                                                                       

  • How to call jsp after reading from ServletInputStream?

              if the client submit a form including FILE type, I usually use ServletInputStream
              to read it and return next page by calling JSP file. but In weblogic6.0Sp1, the
              server will report a exception: One of the getParameter family of methods called
              after reading from the ServletInputStream(), can't mix these two!
              can anyone help me? thanx a lot.
              

    I've seen these messages in the WLS 5.1.0 logs when POSTing to servlets.
              All the reading is done in the servlet and then a JSP handles the view
              rendering. However, I don't actually call getParameter() or it's kin
              anywhere. I thought maybe something inside the JSP generated servlet is
              calling getParameter(), but I've looked at the generated code and can't find
              any calls. If I had a stack trace it would be easier to sort out.
              Is this a warning or an error? Is there a bad side effect. I imagine the
              getParameter() call would fail.
              Dave
              "dancy" <[email protected]> wrote in message
              news:3ac85201$[email protected]..
              >
              > if the client submit a form including FILE type, I usually use
              ServletInputStream
              > to read it and return next page by calling JSP file. but In
              weblogic6.0Sp1, the
              > server will report a exception: One of the getParameter family of methods
              called
              > after reading from the ServletInputStream(), can't mix these two!
              > can anyone help me? thanx a lot.
              

  • How to register a custom plsql code

    Hi
    i have wrritten a custom plsql code for my Overtime entries validation for payroll processing.
    Can any body tell me how to register it in application.
    Secondly i want to get the output file generated by report submission on my desktop.i want to know where the report output files for HR and payroll are stored so that i can get them through FTP.
    Regards

    if you want to integrate your plsql into a fast formula, please download the fast formula guide from metalink. Or ask your functional payroll consultant.
    All reports and processes in Oracle Apps are handled via concurrent programs and requests. When a concurrent request is finished, click on the output button, and depending from the filetype, your browser will take action.
    All concurrent output is also stored on the concurrent server. Ask your apps dba where she mapped the concurrent output directory. But i do not see why you should need this.

  • How to call codec in java code

    i want to call a jmf codec for video compression form direct capture device, i dont know how to call codecs of Jmf i am using jffmpeg how to implement it can any one please let meknow

    Lot of examples are given in the below link
    http://www.oracle.com/technology/sample_code/tech/java/jsp/oracle9ijsp.html

  • How to call JSp from Servlet??

    Hello,
    I want to call JSP page from servlet.I am using Visual Age For java 3.4. What is wrong in my code??
    if (userExists) {
    f.setErrors("userName","Duplicate User: Try a different username");
    getServletConfig().getServletContext().
    getRequestDispatcher("/jsp/forms/retry.jsp").
    forward(request, response);
    I am not able to get the o/p. Pls help.

    I can't see anything obvious, but did you take any steps towards doing output before this code (like openning an output stream)?
    Not clear what f.setErrors does - presumably stuffs the error message in an attribute of the request.

  • How to call jsp from web dynpro app.

    Hi Frndz,
    How can I call a JSP from my web dynpro(and here i don't want to redirect to JSP ),I want to call a JSP which can show a message window as alert on top  of WDP view.
    Here am using CE 7.2 SP1, and my requirement is to call the model(back end) for every minute interval and need to give alert that how many new records r added.With WDP java i haven't find any option to give alert r notifications about new records added, so am thinking to call JSP where I will pass the parameter which can show a alert r notification(like FACEBOOK n outlook notifications).
    Please share any ideas ti achieve this,
    Thanks in advance.
    Regrads
    Rajesh

    Hi,
    If your application should open in a new url, then you can use link to url action to open jsp.
    You can also use EPCF navigation api to call any pcd page as well external links
    i.e
      WDPortalNavigation
          .navigateAbsolute("link",[parameters]);
    Since your passing parameters, you build url in both the cases.
    Ram

  • How to call JSP page from applet?

    I have some page1.jsp from which I call applet.
    User works with this applet but some information does not in date inside applet.
    So user click on some component at applet (some button etc.) and now I would like to do this:
    1) open new window;
    2) call page2.jsp at this new window.
    The reason is that page2.jsp will read some data from database and then displays it in HTML inside page2.jsp itself. It is not necessary to pass these date back to applet for displaying them inside of applet.
    So user then can have 2 windows: page1.jsp with applet and page2.jsp with some details information.
    But I DO NOT know how to call page2.jsp from applet, and do ti in a new window. Is it possible and how?
    Thanks
    Mirek

    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class MainMenu extends JApplet implements ActionListener
         private JMenuBar mbar;
         private JMenu Master,Leave,Report,Logout;
         private JMenuItem UserMaster,DeptMaster,DesignationMaster,LeaveAvailable,LeaveApply,Generate;
         private JPanel jp;
         public void init()
              mbar=new JMenuBar();
              Master=new JMenu("Master");
              Leave=new JMenu("Leave");
         Report=new JMenu("Report");
              Logout=new JMenu("Logout");
              UserMaster=new JMenuItem("UserMaster");
              UserMaster.setMnemonic('U');
              DeptMaster=new JMenuItem("DeptMaster");
              DeptMaster.setMnemonic('D');
              DesignationMaster=new JMenuItem("DesignationMaster");
              DesignationMaster.setMnemonic('D');
              LeaveAvailable=new JMenuItem("LeaveAvailable");
              LeaveAvailable.setMnemonic('L');
              LeaveApply=new JMenuItem("LeaveApply");
              LeaveApply.setMnemonic('L');
              Generate=new JMenuItem("Generate");
              Generate.setMnemonic('G');
              Master.add(UserMaster);
              Master.add(DeptMaster);
              Master.add(DesignationMaster);
              mbar.add(Master);
              Leave.add(LeaveAvailable);
              Leave.add(LeaveApply);
              mbar.add(Leave);
              Report.add(Generate);
              mbar.add(Report);
              mbar.add(Logout);
              UserMaster.addActionListener(this);
              DeptMaster.addActionListener(this);
              DesignationMaster.addActionListener(this);
              LeaveAvailable.addActionListener(this);
              LeaveApply.addActionListener(this);
              Generate.addActionListener(this);
              Logout.addActionListener(this);
              mbar.setVisible(true);
              Container con=getContentPane();
              con.add(mbar,BorderLayout.NORTH);
         public void actionPerformed(ActionEvent ae){
              if(ae.getSource()==UserMaster)
              }

  • How to call jsp /servlets running in different web application in tomcat

    hello all,
    i have 2 web applications(Charts and Reports) in the same tomcat,i want to call jsp/servlets running in the Reports webapp from Charts webapp.how do i achieve this.
    thanx
    ravi

    You can also use getContext(String context) in the ServletContext class to get a request dispatcher.
    Using the above example it would be :
    // in a servlet in the charts webapp
    ServletContext context = getServletContext();
    ServletContext reportsContext = context.getContext("/reports");
    RequestDispatcher dispatcher = reportsContext.getRequestDispatcher("/path")
    dispatcher.forward(request, response);Just note, that depending on your server's configuration getContext(...) might return null.

  • How to call a screen /t-code by double clicking on the output of an alv?

    Hi,
    I want to call a screen /  t-code on double clicking on the output of an alv report.
    Suppose we click on a value in the "Pur Req" feild of the ALV output  it should  open the the transaction code and give us  the  details of that particular value. How can I do that?
    Thanx in advance..

    If you displaying ALV using Classes..( CL_GUI_ALV_GRID)... You need to create event receiver and register the double click event handler method dynamically.... Here's the sample code...
    *                            C L A S S E S                             *
    class lcl_event_receiver definition.
      public section.
        methods:  handle_double_click
                  for event double_click
                  of cl_gui_alv_grid
                  importing e_row e_column.
    endclass.
    *       CLASS lcl_event_receiver IMPLEMENTATION
    class lcl_event_receiver implementation.
      method handle_double_click.
        data: l_cc like line of gt_cc.
        data:
        g_row type i,
          g_value(10),
          g_col type i,
          g_row_id type lvc_s_row,
          g_col_id type lvc_s_col,
          g_row_no type lvc_s_roid.
    *  Read the double click cell
        call method gr_grid->get_current_cell
               importing
                 e_row     = g_row
                 e_value   = g_value
                 e_col     = g_col
                 es_row_id = g_row_id
                 es_col_id = g_col_id
                 es_row_no = g_row_no.
        clear wa_itab
        read table gt_itab index g_row_id into wa_itab.
        case g_col_id.
          when 'EBELN'.                   "Show Process Order
            if not wa_itab-ebeln is initial.
              set parameter id 'BES' field wa_cc-ebeln.
              call transaction 'ME22N'  and skip first screen.
            endif.
        call method gr_grid->set_table_for_first_display
            exporting
            i_consistency_check   =  g_consistency_check
            it_toolbar_excluding  =  gt_exclude
            is_variant            =  gs_variant
            i_save                =  g_save
            i_default             =  'X'
            is_layout             =  g_layout
        changing it_outtab        =  gt_cc[]
                 it_fieldcatalog  =  gt_fieldcat[]
                 it_sort          =  gt_sortcat[].
        create object event_receiver.
    *   Register the 'Double Click' event handler method dynamically.
        set handler event_receiver->handle_double_click for gr_grid.

  • How to call jsp/ejb in webdynpro applications

    Hi
    Is It Possible to call jsp and EJB in webdynpro applications.If it is please let me know..
    Regards
    Chandra

    Hi,
    You can call JSp and serlvets using suspend and resume plugs
    /people/bertram.ganz/blog/2006/07/03/web-dynpro-java-foundation--whats-new-in-sap-netweaver-2004s
    http://help.sap.com/saphelp_nw04s/helpdata/en/42/bb8c6cc7131d67e10000000a1553f6/frameset.htm
    For EJbs you can create a DTO and try to make use of the model import available in Webdynpro.
    Regards
    Ayyapparaj

Maybe you are looking for

  • Problem while print preview purchase order for new document type

    Dear Experts, I have got the problem as below and need your helps. I created a new purchasing document type and then created a new PO with this document type. PO was created successfully in the system. I added a message to print out PO with the follo

  • Set waveform chart size to value 1000

    Is there any possibility to set the size of waveform chart buffer to value >1000 in LabVIEW? Message Edited by Konigusko on 05-03-2006 09:40 AM

  • LabVIEW load error code 3 when opening VI with LabVIEW 2010

    I got this error when I try to open a VI saved in 8.6.1 with LabVIEW 2009 and 2010. The VI open correctly with 8.6.1. It's appening with only one VI. All other VIs are OK. Anyone experience this problem? What can I do to get over this bug? Dany Dany

  • ISA ICSS FUNCTIONAL

    Hello Gurus, I have recently entered the world of ISA - ICSS on the functional side & would like to get a good understanding of what exactly: 1)A functional role in ISA & ICSS is expected to do? 2)What are the various configurations, settings , step-

  • Middle Eastern versions

    Hallo people from Adobe or whoever can help us in this matter. Previously, Middle Eastern versions were supported by third-party companies (WinSoft). In CS6, Adobe has taken over development, support, and sales of such versions. However they have not