How to refresh JSP page?

Hi,
How can I refresh my JSP Page?
I am addind and deleting some mrecords with pressing button on my JSP page, but everytime I have to use browser's back button and hit refresh to see the updates.
How can I just refresh it every time I update the page..
Your help will be appreciated.
Thanks

int i = delete_Customer(delName);
                       System.out.println("i:"+i);
                       if (i==1)
System.out.println("Sending response");                           
response.sendRedirect("/abc/CustomerList.jsp");
int delete_Customer(String delName) {
               // TODO Auto-generated method stub
               int i=0;          
               Statement stmt = null;
               Connection con = null;
               try
                    System.out.println("In Try block for Deleting values");
                    Class driverClass = Class.forName("COM.ibm.db2.jdbc.app.DB2Driver");
                    Driver driver = (Driver) driverClass.newInstance();
                    DriverManager.registerDriver(driver);
                    con = DriverManager.getConnection("jdbc:db2:" + DB2Server, DB2UserID, DB2pass);
                    stmt = con.createStatement();
                    System.out.println(delName);
                    String query =
                         "DELETE FROM CUSTOMERNAME WHERE Customer_Name = '" +delName.trim()+ "'";
                         System.out.println("Values Deleted");
                          i = stmt.executeUpdate(query);
                         System.out.println("Nrows="+i);
                    stmt.close();
                    con.close();
               catch(Exception e)
                    System.out.println("EXCEPTION : "+e.toString());
                    try
                         System.out.println("Severe error in DELETE, unable to continue");
                         if(stmt != null)
                              stmt.close();
                         if(con != null)
                              con.close();
                    catch(SQLException se)
                         System.out.println(se.toString());
               System.out.println("i:"+i);
               return i;
          }//delete method endsThis is my servlet code.
It's not throwing any error,
it's also going to my system log (sending response) but then it doesn't redirect it to the jsp page.
Thanks

Similar Messages

  • How to refresh JSP pages?

    help i cant get my JSP page to refresh..
    it keeps on displaying the old page even if i have edited the old one.
    im using tomcat 6.0 can someone help me please?

    I am not familiar with Tomcat, but for the App Server I have used before.
    You have to remove the generated class file for the updated jsp files.
    All jsp files will be generated as servlet class.
    If there is an update on the file, you have to remove the class file to see the differences.

  • How to Refresh a Page once saved to database in ADF.

    Hi,
    I created a JSF page using project template as "JSF,ADF,business components".
    There is a List of values displayed in a dropdown list,
    User can create new value and once it is saved to the database it should reflect in the list of values.But it is not displaying in the LOV and it is happening only when i close that page and open a new one.
    Can u please tell me how to refresh a page without closing the current page once save button is clicked.
    Thank you,
    Harika.

    Mini wrote:
    Hi Hari,
    Yes i have a apex page redirects from the ebs menu like you said. But for the refresh issue instead of modifying in the jsp i thought of bringing the automatic refresh for that apex page once it is loaded within apex.
    However these type of issues are sometimes get fixed by clearing browser cache or just by restarting your browser. Have you tried it?Yes i have tried, by clearing the browser cache and also by restarting the browser then too it still persist.
    Any DA action will be helpful for refreshing that page for 1sec once it is loaded. Since i dont want it to be loaded multiple times often once it is loaded.
    The refresh has to be only once if the page is loaded.
    or is it possible to Refresh the page based on the application page item through DA
    Thanks
    Brgds,
    MiniTechnically Yes, you can create a D.A. that will fire only once based on some apex page item or application item value. However this is NOT the correct solution.
    <li> When you see apex page (after clicking menu in EBS), do you see apex url in browser address bar? Can you post the URL here?
    <li> If you directly log-in to APEX (not via EBS), do you still face this issue?
    Regards,
    Hari

  • How to run JSP pages in weblogic 8.1 sp2

    hi frnzs,
    plese give me some idea about how to run JSP pages in weblogic server.

    enen i dont know hw to fly palne otherwise i can definitely give u sm guides abt that......

  • How to refresh a page in apex, once it is loaded

    Hi friends,
    I need to refresh the entire apex page automatically, once after the page is loaded. How to achieve this in apex.
    Whether need to use any DA for the auto-refresh. If so, can you kindly help me with that guys.
    Thanks
    Brgds,
    Mini

    Mini wrote:
    Hi Hari,
    Yes i have a apex page redirects from the ebs menu like you said. But for the refresh issue instead of modifying in the jsp i thought of bringing the automatic refresh for that apex page once it is loaded within apex.
    However these type of issues are sometimes get fixed by clearing browser cache or just by restarting your browser. Have you tried it?Yes i have tried, by clearing the browser cache and also by restarting the browser then too it still persist.
    Any DA action will be helpful for refreshing that page for 1sec once it is loaded. Since i dont want it to be loaded multiple times often once it is loaded.
    The refresh has to be only once if the page is loaded.
    or is it possible to Refresh the page based on the application page item through DA
    Thanks
    Brgds,
    MiniTechnically Yes, you can create a D.A. that will fire only once based on some apex page item or application item value. However this is NOT the correct solution.
    <li> When you see apex page (after clicking menu in EBS), do you see apex url in browser address bar? Can you post the URL here?
    <li> If you directly log-in to APEX (not via EBS), do you still face this issue?
    Regards,
    Hari

  • How to refresh JSP automaticlly?

    Hello,
    I need to refresh my Jsp automaticlly every five minutes. How can I realize it?
    Thank you very much.
    Regards,
    Annie

    In you JSP page, add this HTML tag in the header (HTML):
    <meta http-equiv='refresh' content='5;URL=/yourpath/yourpage.jsp'>

  • While refreshing jsp page through javascript

    Hi,
    I am refreshing a jsp page by calling javascript method -'reload()', when its child window is closed. It is displaying a confirmation box saying 'whether to resend the request for refreshing the page.....' with two buttons-ok and cancel.
    How do I avoid this confirmation box ? I want to reload the jsp page without asking any confirmation msg.
    Please help me out.
    thanks
    --Karthik                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    if you use meta refresh you will lose your data your best bet is to create an object relating to your page, basically a bean and store all your values into that bean, save it into the database then recall after refresh, but make sure you test that the object contains something before retrieving the values from it

  • How to add Jsp pages into existing portal (JDeveloper 9.0.4)

    I am a jsp developer. I have to add a jsp page into existing portal. I am new to portal. Could anyone help me how to develop jsp using portal classes like PortletRenderRequest,ProviderSession and others.

    Rigoberto, there should be no space between "-Xbootclasspath/p:" and the path "C:\oracle\infra\jdbc-10.1.0.4\ojdbc14.jar;C:\oracle\infra\jdbc-10.1.0.4\orai18n.jar"
    By the way, one can always take a look at the logs at
      $ORACLE_HOME/opmn/logs
    especially those files whose names start with OC4J~ if there is some wrong with oc4j processes. Those files are the default oc4j stout and sterr. If oc4j can not init, there should be some kind of error message in them.
    By the way, the following line may be deleted since no property file is specified.
      <data id="oc4j-options" value="-properties"/>
    Hope this helps.

  • How to customize JSP page in iSupport

    Hi,
    I have worked on OA framework. But I have got a requirement to customize iSupport page in oracle apps. There is a Next button on page, I want to call one DB function by passing 2 parameters to this function. Get the result from that function and show the error message to user based in result of function.
    This page is JSP page. I got the JSP page name from URL in browser. I view the source of that page and found following statement..
    onclick="javascript:document.identifyproblem.JTFValidateFlag.value='Yes';*next*('identifyproblem', 'NEXTFROMIP'); return false " type="button">Next</button><img src="/OA_HTML/cabo/images/swan/t.gif" width="10" height="10"></td></tr></table>
    "next" function is available in one .js file which is imported in above file.
    function next(form, opcode)
    if (opcode =='NEXTFROMCI' || opcode =='NEXTFROMIP') {
    if (!checkContactPoint(form)) return;
    if (checkRequiredField(form)) {
    document.forms[form].IBU_CF_SR_OPCODE.value=opcode;
    document.forms[form].submit();
    else {
    return;
    If I want to change the functionality can I add my code in above "next" function?
    Or I will have to change something in controller file of that page??

    Hi Paraq,
    if you want to extend a seeded Oracle E-Business suite page you should use the personalization framework combined with a custom controller. Personalisations are done via the ebusiness suite user interface and involve no coding and allow you to intergate custom components into the app.
    Controller extensions are not recomended in E-Business suite however they are commonly implemented. You can personalise the page/region/table controller etc... to call your custom controller when they are invoked. See the OAF Personalization/Development guide for details on how to do this.
    One problem you will have here is that if you want to modify an existing controller you will need the source code which would probably mean getting an Oracle consultant or you could decompile the class files, failing that if you can bypass the existing controller by personalizing a different aspect of the page i.e. a region or table that doesnt already have a controller then you might get away with it.
    Keith

  • How to refresh a page in Safari

    In IE there is refresh option.  How can I refresh a web page in Safari?

    Maybe there is a misunderstanding, but normally you need to refresh the page when there is something wrong. I often have small issues for instance with flickr, a picture does not display because of their servers (some farms are sometimes not active, then get active again). The pictures display as a question mark in a small blue square. If the pictures are restored, and you refresh the page on Safari, the picture will NEVER display, you need to clear the cache. The only way to do this is the following (found in another forum post):
    1. Go to Safari > Preferences > Advanced and select Show Develop menu in menu bar.
    2. Go to Develop > Empty caches
    If you THEN refresh the page, the content will be displayed correctly.

  • How does a JSP page remember a user and prints in every page name of user?

    Hello, i'm working with JSPs and mysql.
    I have a Login page where sm inserts data in the two fields:
    name, username.
    i check if that user exists in the database.
    if the user exists i would like in every jsp page to mention/appear his name.
    As happens in this site [forums.sun.com] where it says "Welcome user" and
    when you click on it you are transferred in your profile page.
    How am i supposed to do that using JSP?
    May sm post me an example or a link to study that particular matter?
    thanks, in advance!

    This is covered by every decent JSP book/tutorial.
    Recommended book: [Head First Servlets & JSP|http://www.amazon.com/Head-First-Servlets-JSP-Certified/dp/0596005407] of Bates and Sierra.
    Recommended tutorial: [http://java.sun.com/javaee/5/docs/tutorial/doc/] (just Part II is enough).
    Alternative tutorials: [http://courses.coreservlets.com/Course-Materials/csajsp2.html].

  • How can a jsp page tell which Oracle Responsibility the user has selected?

    We have two responsibilities - Timecard Administrator and Timecard Viewer. Everything that they can access is the same, except for one particular jsp page which we want to present a slightly different view if the user's responsibility is Timecard Viewer (specifically, the edit link in the results page will be suppressed). Unfortunately in order to implement this, the jsp code needs to be able to distinguish which of those two responsibilities the user has selected. I have written jsp code to print all the environment variables and unfortunately the environment is essentially identical regardless of which of the two responsibilities the user selected.
    How do I pass in the active responsibility to that page/environment in a way that can be tested by the jsp code?
    Thank you,
    Graham Toal <[email protected]>

    Yes, I tried something like this (shortened to the basics for this post):
    <pre>
    sqlQuery="select responsibility_name from fnd_responsibility_vl where responsibility_id = FND_GLOBAL.RESP_ID";
    stmt=con.createStatement();
    rs=stmt.executeQuery(sqlQuery);
    int field_count=rs.getMetaData().getColumnCount();
    while (rs.next()) {
    for (int i=0; i<field_count; i++) {
    logger.write("Responsibility: "+rs.getObject(i+1),"JSP",objName,0,-1,1001);
    </pre>
    However it did not print any results at all.
    I'm trying a different approach at the moment - I've cloned the menus from the Administrator responsibility to the new Viewer responsibility, and have altered the top-level menu so that I can insert a new variable into the process state myself; that way by the time the user navigates to the changed page, there should be a variable there that can be tested.
    Unfortunately the top-level menu isn't just a simple menu, it's a piece of code that issues an HTML redirect depending on the parameter passed in - which is set in the Oracle function screen for the function attached to that menu.
    (was something like utpa_top_menu.jsp?ADMIN and I changed it to utpa_top_menu.jsp?VIEWER, with appropriate tests for the new module name:
    <tt>
    else if ("VIEWER".equals(moduleName))
    url = "/utpa/jsp/admin_reports-viewer.jsp";
    </tt>
    In admin_reports-viewer.jsp I've added <tt>session.putValue("REPVIEWER","y");</tt> and in the actual target main page I have:
    <pre>
    if (session.getValue("REPVIEWER") == "y") {
    // viewer
    out.println("<CENTER><B>You are using the Timecard Viewer responsibility</B></CENTER><BR>");
    } else {
    </pre>
    And although the URL bar at the top of the screen is displaying the correct (redirected) URL, the page that is displayed is blank. Completely empty. 0 bytes. The file is present on the filing system; has content; has the correct ownership and permissions; I've reloaded apache, even had the systems guys reboot completely. I'm at a loss :-/
    Graham

  • How to include jsp page in jsf ???

    Hi,
    I use JDeveloper 11g and the framework ADF. I want to include a jsp page in another page ( jsf page).
    In fact, I do this :
    <f:view>
    *<jsp:include page="/Menu/MenuGlobalDynamique.jsp"/>*
    </f:view>
    when i run my jsf page nothing is displayed and i have this error :
    javax.servlet.ServletException: Erreur OracleJSP :
    oracle.jsp.parse.JavaCodeException: Ligne n° 19, oracle.jsp.parse.JspParseTagDeclaration@cf767d <br>Erreur : Java code in jsp source files is not allowed in ojsp.next mode.
         at oracle.jsp.runtimev2.JspReportUtil.reportException(JspReportUtil.java:180)
         at oracle.jsp.runtimev2.JspPageTable.compileAndServe(JspPageTable.java:692)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:379)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:722)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:646)
    Have you an idea to help me and resolve my problem.
    Thank you.

    Hi,
    Can you post the source of the MenuGlobalDynamique.jsp page?
    if MenuGlobalDynamique.jsp is a JSF page and you want to include it into other JSF page you must mark out (or delete) this parts from the MenuGlobalDynamique.jsp like here:
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0"
              xmlns:f="http://java.sun.com/jsf/core"
              xmlns:af="http://xmlns.oracle.com/adf/faces"
              xmlns:afh="http://xmlns.oracle.com/adf/faces/html">
      <jsp:output omit-xml-declaration="true" doctype-root-element="HTML"
                  doctype-system="http://www.w3.org/TR/html4/loose.dtd"
                  doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN"/>
      <jsp:directive.page contentType="text/html;charset=UTF-8"/>
    <!--
      <f:view>
        <afh:html>
          <afh:head title="impForm">
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
          </afh:head>
          <afh:body>
            <af:messages/>
            <af:form>
    -->
    <!--
            </af:form>
          </afh:body>
        </afh:html>
      </f:view>
    -->
    </jsp:root>regards,
    Branislav

  • How to load jsp page in Frame?

    hi
    I have tried to make an Application which is a very simple Messenger made by java.awt.Frame
    and had problem to load/open jsp page.
    Is there any way to load/open jsp page in Frame When an event occured?
    It makes me crasy these days.
    Please Help me.
    Thank you and have a nice day!
    Sorry about my English^^

    I think we need more info than that.
    Why do u want to open JSP in a Frame? do u want to open it with all the JSP code still there (for editing), or do u just want to display the HTML which is created after executing the JSP.
    You will need Tomcat or JRun or another servlet/JSP engine to execute a JSP. do u have it installed? and the fact that u have win2000 and sql server 2000 doesnt really shed any light on your problem and what u r trying to acheive.
    Post more info and hopefully we'll be able to help u better.

  • 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                                                                                                                                                                                                                   

Maybe you are looking for

  • Itunes 10.6.1 update

    I have tried over 10 times, but there is always an error while trying to update to version 10.6.1, whether I do it automatically or manually. I have an HP, not a mac. What can I do?

  • BAPI function module name and mandatory fields

    Give the name of BAPI function module for pricing change into the transaction VA05 ? What are the mandatory fields ? Please give a exemple code to do this.

  • Adobe Photoshop CS6 won't install my CS6 trial.

    My OS is Windows 7. I downloaded Adobe Downloader Assistant, downloaded CS6, and clicked on the 'setup' file, and it gave me an error mesagge saying that there was a prerelease/other version of CS6 interferring, and I had to uninstall it before I cou

  • E-mailing photos to a mms address

    first thank you all for posting the web addresses for getting around the no mms feature on the iphone. my question is: To view a mms message on the iphone is there a way to get around writing down, and then typing in the Msg ID and password via a cut

  • Audio goes off on videos

    When watching or listening to videos on any website, the audio randomly cuts off, and I have to pause then unpause the video for it to resume the audio. This only just started happening today, I had never had problems with the audio at all ever befor