Refresh the screen after a long calculation

          Hi,
          I have a problem here:
          After I click a submit button, I want start a long process(running a stored procedure
          in
          database for about 20 mins) and after it is finished, screen will refresh automatically
          to reflect
          changes. I was using a thread to do the calculation but not able to refresh the
          browser after calculation is finished. Any one knows how to do it?
          Thanks.
          Kim
          

Kim,
          It was just pseudo-code to hand you an idea of using Refresh.
          As for the piece you provided, it has some problems:
          1. It looks like you start marginServer() Every time there is a refresh
          2. It looks like you have marginServer as a field in the servlet, which
          is not correct as it's not guaranteed that the same instance will serve
          the next request. You'd better keep in HttpSession.
          HTH.
          Regards,
          Slava Imeshev
          "Kim" <[email protected]> wrote in message news:[email protected]...
          >
          > Hi Slava,
          > Thanks for helping.
          > I tried your code but got some error . Here is the code:
          > public class LongRunningTaskRefresh extends HttpServlet {
          > public void doGet(HttpServletRequest request, HttpServletResponse response)throws
          > ServletException, IOException {
          > stillRunning =true;
          > marginServer.start(); //this is the thread with long
          > process. In the end of it, it will set stillRunning to false
          >
          > response.setContentType("text/plain");
          > PrintWriter out = response.getWriter();
          > if (stillRunning) {
          > response.setHeader("Refresh", "5");
          > out.println("Your request is being processed" );
          > }
          > else {
          > rd = request.getRequestDispatcher("MarginSummary.jsp");
          > rd.forward(request,response);
          > }
          > }
          > }
          >
          > Do I do anything wrong?
          >
          > THanks again!
          >
          > Kim
          >
          

Similar Messages

  • Refresh the screen after a ALV hotspot click

    I have a value type I painted on my screen, i wan it to be updated after i trigger the hotspot click on my ALV list. How to do refresh the value on the screen?Because hotspot click does not update the screen for the latest value.

    Hello Lai
    I trigger PAI in the event handler method using the following coding:
    *   Trigger PAI
        CALL METHOD cl_gui_cfw=>set_new_ok_code
          EXPORTING
            new_code = e_ucomm
    *      IMPORTING
    *        rc       =
    When you are at PAI you can do all kinds of refreshing your ALV list before displaying it again. For an example see thread
    Blanking values on ALV Grid Row Duplicate
    Regards
      Uwe

  • Time trigger for refreshing the screen

    Hi all,
    How to implement the time trigger for refreshing the screen after some time interval .
    Thanks in advance .

    hello Naval ,
    set the delay propert Eg : 10
    in the on action of the Time trigger Ui
    invalidate the node of table .
    write the select query for retrivig the PO from table into Itab .
    bind the internal table to the node ...
    But for your requirement it will efficient if you implement POWL query .
    [http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60f1d5ee-84ab-2c10-ce97-97dfd89bc238?quicklink=index&overridelayout=true]
    Regards
    Chinnaiya  P

  • My new iphone 5 is frozen, with the cord to computer symbol on the screen after failing to finish updating to ios 7.  iTunes no longer sees the phone. I've tried rebooting the computer, rebooting the iPhone, but iTunes still doesn't see the iPhone.

    my new iphone 5 is frozen, with the cord to computer symbol on the screen after failing to finish updating to ios 7.  iTunes no longer sees the phone. I've tried rebooting the computer, rebooting the iPhone, but iTunes still doesn't see the iPhone.

    If your computer doesn't see the phone when you plug it in, you may have to take it to an Apple Store.

  • When using rogers.yahoo mail, I need to refresh my screen after every 2-3 actions.

    While using Rogers.yahoo mail in FireFox, the screen freezes after every 2-3 actions (read email, delete email, respond to email, move email to folder etc.). I have to refresh the screen and then it goes along for another 2-3 actions and I have to refresh again. Very frustrating. I opened the same email account in Google Chrome and IE and it works fine there. This started happening yesterday.
    In perhaps an unrelated thing, I get this error message every day, once, when I start up my PC for the past 2 months:
    Microsoft.NET Framework
    Unhanded exception has occurred in your application If you click Continue, the application will ignore this error and attempt to continue. If you click Quit, the application will close immediately. Unable to load DLL 'hppatusg01.dll': The specified module could not be found (Exception from HRESULT:0x8007007E)

    No problem.
    If the above does not fix the issue, '''try Firefox Safe Mode''' to see if the problem goes away. [[Troubleshoot Firefox issues using Safe Mode|Firefox Safe Mode]] is a troubleshooting mode that turns off some settings and disables most add-ons (extensions and themes).
    ''(If you're using an added theme, switch to the Default theme.)''
    If Firefox is open, you can restart in Firefox Safe Mode from the Help menu by clicking on the '''Restart with Add-ons Disabled...''' menu item:<br>
    [[Image:FirefoxSafeMode|width=520]]<br><br>
    If Firefox is not running, you can start Firefox in Safe Mode as follows:
    * On Windows: Hold the '''Shift''' key when you open the Firefox desktop or Start menu shortcut.
    * On Mac: Hold the '''option''' key while starting Firefox.
    * On Linux: Quit Firefox, go to your Terminal and run ''firefox -safe-mode'' <br>(you may need to specify the Firefox installation path e.g. /usr/lib/firefox)
    ''Once you get the pop-up, just select "'Start in Safe Mode"''
    [[Image:Safe Mode Fx 15 - Win]]
    '''''If the issue is not present in Firefox Safe Mode''''', your problem is probably caused by an extension, and you need to figure out which one. Please follow the [[Troubleshoot extensions, themes and hardware acceleration issues to solve common Firefox problems]] article to find the cause.
    ''To exit Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again.''
    When you figure out what's causing your issues, please let us know. It might help others with the same problem.
    Thank you.

  • Since I have upgraded to ios7 my internet banking page will not fit the screen. Before updating I enlarged the page by using the *2 button in the bottom right hand of the screen, there no longer is that option?

    Since I have upgraded to ios7 my internet banking page will not fit the screen. Before updating I enlarged the page by using the *2 button in the bottom right hand of the screen, there no longer is that option?

    Install or Reinstall OS X from Scratch
    Be sure you backup your files to an external drive or second internal drive because the following procedure will remove everything from the hard drive.
    Boot to the Recovery HD:
    Restart the computer and after the chime press and hold down the COMMAND and R keys until the menu screen appears. Alternatively, restart the computer and after the chime press and hold down the OPTION key until the boot manager screen appears. Select the Recovery HD and click on the downward pointing arrow button.
    Erase the hard drive:
      1. Select Disk Utility from the main menu and click on the Continue button.
      2. After DU loads select your startup volume (usually Macintosh HD) from the
          left side list. Click on the Erase tab in the DU main window.
      3. Set the format type to Mac OS Extended (Journaled.) Optionally, click on
          the Security button and set the Zero Data option to one-pass. Click on
          the Erase button and wait until the process has completed.
      4. Quit DU and return to the main menu.
    Reinstall OS X: Select Reinstall OS X and click on the Install button.
    Note: You will need an active Internet connection. I suggest using Ethernet if possible
               because it is three times faster than wireless.

  • I am have problems with the ipad mini, it is a little crazy. It controls by itself, opens and closes application zooms in and out, end my facetime calls, Also Un certain part of the screen is no longer responsive to the touch.

    I am have problems with the ipad mini, it is a little crazy. It controls by itself, opens and closes application zooms in and out, end my facetime calls, Also Un certain part of the screen is no longer responsive to the touch, it Should be having so much problems. Thanks for your help.
    iPad, iOS 7.0.4

    Try reset iPad
    Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears
    Note: Data will not be affected.

  • Images burn into the screen after being there for only a few minutes?

    What's wrong with my mac if images burn into the screen after being there for only a few minutes?
    I can have an icon, like a folder or something, on my desktop for only a few minutes and then when I move it an image of it will be burned into the screen for another few minutes. Same thing happens with having a webpage open for a few minutes or word document. What part of my computer is malfunctioning and is Apple responsible for repairing it?

    Hi,
    Does it happen on all desktops applications as well as Modern UI Apps? Since this issue only happened recently, I suspect a newly-installed third party program causes this issue, please check these programs if possible.
    We can also boot into clean boot mode, test the issue.
    http://support.microsoft.com/KB/929135
    Run a virus scan to eliminate some malware\virus
    Similiar issue
    https://social.technet.microsoft.com/Forums/en-US/125204a0-937e-4bc6-bb60-8fe3244b4514/all-windowsapplications-keep-minimizing-on-their-own-windows-81?forum=w8itprogeneral 
    Yolanda Zhu
    TechNet Community Support

  • No matter what I do, I cannot figure out how to refresh the screen, and so I can't even see what's new on my own website!

    I cannot refresh the screen, no matter what I try. The "restore" is not the same thing. So I always get old versions of websites, including my own. I cannot see a new version of any website I have visited previously. I need to know how to REFRESH my screen, and there is no way to do it!!!!!

    Reload web page(s) and bypass the cache to refresh possibly outdated or corrupted files.
    *Press and hold Shift and left-click the Reload button.
    *Press "Ctrl + F5" or press "Ctrl + Shift + R" (Windows,Linux)
    *Press "Command + Shift + R" (MAC)
    Clear the cache and the cookies from sites that cause problems.
    "Clear the Cache":
    *Firefox/Tools > Options > Advanced > Network > Cached Web Content: "Clear Now"
    "Remove Cookies" from sites causing problems:
    *Firefox/Tools > Options > Privacy > Cookies: "Show Cookies"

  • Since Yosemite my Macbook 11inch mid 2011 does not see second thunderbolt display anymore. My MacBookPro 13inch Early 2013 works fine, but it swaps the screens after an (re)boot

    Since Yosemite my Macbook 11inch mid 2011 (supports Thunderbolt) does not see the second thunderbolt display anymore.
    My MacBookPro 13inch Early 2013 works fine, but it swaps the screens after an (re)boot.
    Does anyone else experience these problems and/or have solutions

    Hello ROBLAHAY,
    I'm sorry to hear you are having this issue with your MacBook Air. I also apologize, I'm a bit unclear on the exact configuration you are describing. If you are talking about using two external Thunderbolt displays (in addition to the internal display) with your Mid 2011 MacBook Air 11-inch, you may want to be aware that only a single external Thunderbolt display is supported on that model, as noted in the following article:
    3. How many Apple Thunderbolt Displays can I use with my Mac in OS X?
    The table below indicates how many Thunderbolt displays can be connected to Thunderbolt-capable Mac computers in OS X.
    Computer
    Maximum connected displays
    Thunderbolt-capable Macs with Intel HD Graphics 3000 integrated graphics can support one connected Apple Thunderbolt Display (27-inch).
    MacBook Air (Mid 2011)
    MacBook Pro (13-inch, Early 2011) and (13-inch, Late 2011)1
    Mac mini (Mid 2011), 2.3 GHz
    Mac mini with Lion Server (Mid 2011)
    One Thunderbolt display
    Thunderbolt ports and displays: Frequently asked questions (FAQ) - Apple Support
    If you are using just a single external display and still having issues, you may find the troubleshooting steps outlined in the this article helpful:
    Apple computers: Troubleshooting issues with video on internal or external displays - Apple Support
    Sincerely,
    - Brenden

  • How to enable the screen after triggering the error message

    Hi All,
    we have a tcode IW31, in that one field(WBS element -PROID) is not mandatory. so we have written the following code to make it mandatory in a user exit EXIT_SAPLCOIH_010.It's triggering the error message, but it is going into disable mode. Please sugget me how to enable the screen after getting the error message triggering.
    if not caufvd_imp-proid is initial.
      select single * from t350 into wa_t350
              where  auart    = caufvd_imp-auart
                and  imord    = 'X'.
      if sy-subrc is initial.
        pspel = caufvd_imp-proid.
      else.
        call function 'CONVERSION_EXIT_ABPSP_OUTPUT'
             exporting
                  input  = caufvd_imp-proid
             importing
                  output = l_posid.
        concatenate text-t10 l_posid text-t11
                    into l_textline1 separated by space.
        message i208(00) with l_textline1.
      endif.
    else.
      message e208(00) with 'Please maintain WBS element in Location Tab'.
    endif.
    Thanks

    Hi,
    Instead of error message use status message like
    message s208(00) with 'Please maintain WBS element in Location Tab'.
    Leave to screen sy-synnr.
    This will allow to move to the screen and have in enable mode.
    WIth Regards,
    Dwaraka.S
    Edited by: Dwarakanath Sankarayogi on Feb 13, 2009 7:46 AM

  • HT1430 My Ipad won't start up.  The apple logo appears and just stays on the screen. after a while it starts blinking every minute

    My Ipad won't start up.  The apple logo appears and just stays on the screen. after a while it starts blinking every minute

    Try recovery mode as described here.
    Note you may have to try to enter recovery mode more than one time to succeed.
    HT1808

  • Firefox 4.01 keeps dimming the screen after a few secnds unless you keep moving the mouse.This is very annoying. It doesn't do it on Explorer or while in Windows so it is only happening ince I upgraded to 4.01

    Firefox 4.01 keeps dimming the screen after a few seconds
    unless you keep moving the mouse. This is very annoying.
    It doesn't do it on Explorer or while in Windows.
    It is only happening since I upgraded to 4.01
    It happens even on this page if I stop typing or moving the mouse.

    Symantec have released an update for Norton 360 to make it compatible with Firefox 4, for details see http://us.norton.com/support/kb/web_view.jsp?wv_type=public_web&docurl=20100720113635EN&ln=en_US

  • HT1365 How can I get my iPhone 4 to update my updates from my app store of it keeps telling me error 3150 or it tell me to refresh the page after updates and the updates are still there asking me to update them again

    How can I get my iPhone 4 to update my updates from my app store of it keeps telling me error 3150 or it tell me to refresh the page after updates and the updates are still there asking me to update them again?

    Make sure iTunes on the computer is logged into the account on the phone.
    Plug the iPhone in.
    In the popup window warning about wiping your phone, hit cancel.
    In the left pane of iTunes, the phone icon should be there.
    Right click on it, select transfer purchases.
    Note: this will only transfer music bought from iTunes. Not mp3's from amazon or ripped from CD's.

  • Have to keep refreshing the screen

    When I start up various applications under Firefox, the username and password are not always completed for me despite being stored. If I refresh the screen, then it works. Also, when using the back button in google, it takes me to a completely blank page instead of the list of returned items - again, if I refresh the screen, the correct list is displayed. This has only been happening in the last 2 weeks and it's driving me nuts.
    I've looked on this forum for answers but there aren't any that explain why this is only happening with Firefox. I left IE because of problems, don't tell me I have to now abandon Firefox too? Has anyone got a reliable platform out there for goodness sake?

    Ok. I think safe mode should be the next step then.
    I should have been more clear above. I didn't mean Windows Safe Mode. I was referring to Firefox's Safe Mode. See the article below:
    [[Troubleshoot Firefox issues using Safe Mode]]
    This basically starts Firefox up with all add-ons disabled and with a couple of changes to basic settings. If the problem doesn't occur in Safe Mode then it is a good bet that some setting or add-on is causing the problem. You can then follow the instructions in that article to enable them one by one to identify the culprit.
    If the problem still occurs in Safe Mode then I suggest doing a Firefox Reset. See the article below. This will return Firefox to its defult settings. Your history, bookmarks etc will be saved but you will need to reinstall all your add-ons.
    [[Reset Firefox – easily fix most problems]]
    I hope that helps. Let me know if not.

Maybe you are looking for

  • Can validation check can be set for vendor master record .

    Hi Experts , User wants to remove two existing payment methods,instead of removing i think to set validation for the vendor master record . can validation can be set for vendor master record ? PLease suggest me with advice. Thanks Pardha

  • Watching iTUNES on TV / using Apple FM receiver with iPHONE

    will either of these be possible with this phone? I used to download tv shows and watch them on tv with my video ipod. Can't do that with the iPHONE. Same with my Apple FM receiver. IT doesn't work. Will this be changed or will a 3rd party make an ad

  • Samsung 46" tv

    Just received a 46" Samsung LCD TV I purchased at Best Buy.  I have it on the stand on top of a level TV cabinet, but I noticed that the TV leans a little at the top towards the room.  Is it supposed to do this (maybe for wall mountng purposes?)  or

  • Time code changes when reconnecting  media

    I have been working on a project for over year. Recently my computer was stolen when shooting abroad and now I had to buy a new one (leopard op sys) and reinstall my software to continue working. As I recapture the lost media a warning window pops ou

  • Spry Validation - Showing a valid message text

    I am having problem finding out how to have a text message pop up when the text is valid in a form Invalid message automatically works fine Thanks