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)
          }

Similar Messages

  • How to call jsp page from OA page

    Hi all,
    I am new to OA Framework..I have a requirement where i have to navigate to a new jsp page.. on clicking a link in the OA page.The major trouble in this is that , that new jsp page should open in a new window.. not in the same window.
    Please give me some solution as it is very urgent for me.
    Thank you.
    Vasantha

    Similar issue has been discussed in last few weeks. Search in threads before posting the issues.
    --Shiv                                                                                                                                                                                                                   

  • Calling jsp page from plsql

    Please help me to the following
    How to Call jsp page from plsql??
    Please its urgent
    Edited by: 883730 on Mar 19, 2012 12:05 AM

    The best approach would be to change the behavior of your site so that it includes index.jsp as one of the default files. Typically that is done using the upper-level control files of the site. Here's a link from Sun that describes their approach.
    http://java.sun.com/j2ee/1.4/docs/tutorial/doc/WebApp4.html
    Actually, you don't say what type of webserver you're using, so it's really hard to guess. But if you were using an Apache webserver, you might want to review the "DirectoryIndex" directive here...
    http://httpd.apache.org/docs/2.2/mod/mod_dir.html
    In fact, if you were using Apache and didn't want to do that, you could do a redirect to another page using the "redirect" directive in the webserver control files as described here:
    http://httpd.apache.org/docs/2.1/en/mod/mod_alias.html#redirect

  • Can I call JSP page from forms6i C/S?

    Hi.
    How can I call JSP page from forms6i Client/Server?
    Flavio.

    What is your problem with a host command? You can use:
    host('c:\program files\internet explorer\iexplore.exe http://server/page.jsp');
    There a disadvantage indeed: you have to close the browser before you can return to the form.

  • Calling JSP file from applet and passing a parameter in POST form

    Hi,
    Can anybody help me. I want to call a JSP page from within a applet and to this JSP page i want to pass the query which the applet has created in POST method.
    I want to refresh the applet page with the new JSP page by passing the query object so the jsp page with take this query, and display the resultset
    Thanks in advance
    JK

    Review
    URL.openConnection()
    and HttpURLConnection

  • Calling jsp page from a java program

    Hello,
    Is it possible to call a JSP page from a java program? If so, please let me know how it is possible.
    I have a JSP page that inserts 10 records in a database based on the attribute given to the page. When the java program is executed all the 10 records need to be inserted.
    The JSP page is already running fine in Tomcat.
    Thanks and Regards,
    Prasanna.

    MVC has applied the standard of seperate your view , model and controller. I believe nobody will insert data from jsp page,better practice should be inserted from your database layer, normally is like DAO layer. so you should pass your data from jsp to your backend.
    hopefully it's help u

  • How to call OAF page from plsql

    Hi OAF Guru's,
    I have a requirement to call a OAF page from a plsql procedure/function, I know how to call procedure/function from OAF pages, but I don't have any idea about how to call a OAF page from plsql.
    Any help is appreciated.
    Thanks in Advance.
    Raja.

    Hi,
    What is your exact requirement. Why do you want to call a OA page from PL/SQL. Please share your requirement clearly.
    HTH,
    Syed.

  • How to call a page from an iview

    HI SDNs
    I have a requirement as follows .
    I need to call a page from an iview .  for that i developed a html and i gave the hyperlink to call the page.
    When i click on hyperlink it is calling page but iviews are not displayed. it is showing masterhead and DLN and but iviews are not shown
    Is there any soultion with out solution to display the iviews.  i Appreciate if you help at the earliest.
    Thanks
    Ramana

    Did you build your hyperlink using "NavigationTarget"?
    ex:
    http://myServer:50000/irj/portal?NavigationTarget=ROLES://portal_content/myFolder/myRole/myPage
    check the below link:
    http://help.sap.com/saphelp_nw04/helpdata/en/43/014421d21d6fade10000000a11466f/content.htm
    Greetings,
    Praveen Gudapati

  • Calling JSP page from BSP

    Dear Guys,
    From  BSP application I want to call a JSP Page. Is itpossible?
    How can we integrate BSP and JSP....?
    Any configuration has to be done.....?
    Regards,
    Shamila

    if you have the url of it you can call from BSP.

  • Redirection to JSP page from Applet not working...

    Hello,
    I have some JSP pages that obtain information and set session variables. Once they have gotten the information, they call an applet to perform some processing, then the applet redirects back to the calling page. My problem is that when the applet redirects using
    getAppletContext().showDocument(reportJspUrl, "_self");
    it seems to be unable to see the session variables that I set in the beginning - consequently I am getting a faulty session timeout error. Has anyone seen this problem? I don't understand why it is happening. It seems that when the applet causes the page to be shown, the page should be able to see the session since it is in the same browser, even in the same frame of the browser.
    Thank you for your help in advance.
    Ali

    Have you tried getting the session in the jsp with req.getSession(false) and confirming that the session returned is not null.

  • Problem in calling JSP page from a servlet

    can anyone please tell me how to call a JSP from servlet?
    My code is:
    ServletContext sc = this.getServletContext();
                                                 RequestDispatcher rd = sc.getRequestDispatcher("./Welcome.jsp");
                                                 if (rd !=null)
                                                      try
                                                           rd.forward(req, res);
                                                      catch (Exception e)
                                                           sc.log("---------------Problem invoking JSP.------------------", e);
    I n the browser when i call this servlet it gives error-404.
    NOT Found.
    please help.

    I would try to change "./Welcome.jsp" to "/Welcome.jsp". I'm not sure what that period will do.
    Are you able to access that JSP directly from your browser (even if it's not designed to be accessed that way)? If not, then you have some other problem.
    When you say you get a 404 when you access the servlet, is that when you access the servlet, or when it tries to forward to the JSP? If you get the 404 when you access the servlet, perhaps your servlet-mapping to the servlet is invalid.

  • How to call JSP function from onClick Action

    Hi
    I am trying to call a jsp function, onclick of a checkbox. This jsp function will in turn connect to the database and gets related information. I dont want to submit the data inorder to avoid posting and getting of huge data. Is there a simple way to call a jsp function from the users onClick action.
    Appreciate anyones help!!!
    Thanks alot
    Joe

    So, i have to submit the form to call the jsp function. Basically yes.
    Sorry for the shortness of the answer, but I am pretty sure we have had this conversation (or one very much like it) before.
    Java/JSP runs on the server, generates an html page, and stops running.
    Javascript runs on the client in the web browser, once the page is loaded.
    You cannot call java code from javascript.
    The only way you can run java code again is to make a request - either by submitting a form, or clicking a link.
    If you don't want to refresh the current page, you CAN get tricky with javascript and multiple frames. You submit to another frame, and when it loads, it uses javascript onload event to call back and modify the main frame. Its tricky to get going, and very easy to break, so I don't normally recommend it.
    Good luck,
    evnafets

  • How to call BSP pages from a BSP application of another package

    Hi,
    I have a BSP application in one package and I want to call pages from another BSP application in a different package.
    Is it possible? How it would have to do it?
    Thanks in advance
    Regards

    Hi,
    You cannot call a page fragment in a seperate window or seperately in the same window...
    Page fragment is used only for including a fragment in your page....
    It is not a seperate page..!
    To call a page fragment, you have to  use the include directive...
    eg :
    <%@include file="Carrier_report_logo.htm" %>
    Hope this helps.
    <b><i>Do reward each useful answer..!</i></b>
    Thanks,
    Tatvagna.
    Message was edited by:
            Tatvagna Shah

  • How to call OA page from Workflow.

    Hi All,
    I have one requirement.
    I have to call a OA page from worklfow..
    There will be alink in the notification and that link should call OA page
    Does I can do in the same way we give destination URI of page property..in button.
    Let me know if anyone has done same.

    You can call an OA page from WF, but then you won't be able to come back to the WF page as WF maintains a list of variable for its operation which would be difficult to track and keep updated.
    When it comes to Workflow, its always adviseable to work through the embedded OA region in the Workflow page. But again according to Workflow standards, you cann't have such an embedded region which has links or buttons capable of <b>Form Submit </b>.
    null

  • How to run jsp pages  from webdynpro java

    Hi experts
         I want to run the jsp pages present in a webserver like tomcat or weblogic servers from webdynpro.Is there any way to run a jsp from webdynpro environment?
    Thanks and regards
    venkat kalyan

    hi Venkat,
    Check out this threads. They might be helpful
    Re: web dynpro jsp
    Re: Opening a jsp from another server(Weblogic) from webdynpro running on WAS
    Regards,
    Gopi

Maybe you are looking for

  • How do I view photos/video

    Gidday I have an SD card with photos/video taken on a digital camera. What do I need to install so I can view them on a Tungsten T2? Can anyone help please? Cheers Glenn

  • Add version numbers in provides=() variable

    Hi, Creating svn packages, i wonder if it is possible to tell that the svn package i create is the equivalent of the version 2.0 on the non-svn package. For example, the gnustep-make-svn packages release 25480 also provides gnustep-make version 2.0 S

  • Hello, why am i getting this message? Photoshop cannot initialize because of a program error.

    Hello, why am i getting this message? Photoshop cannot initialize because of a program error.

  • Connection interface

    Without implementing Connection interface in our class how we are using the some methods of that interface. eg. public class JDBCConnection public JDBCConnection() try Class.forName("com.mysql.jdbc.Driver").newInstance(); con= DriverManager.getConnec

  • Why do my youtube videos have this green screen?

    Im running the latest version of flash player on Google Chrome, what is the problem? https://fbcdn-sphotos-a.akamaihd.net/hphotos-ak-ash3/s320x320/547684_3404327620889_2047119 523_n.jp If I have to uninstall & reinstall, can someone give me steps to