Re: 'Please wait' on long operation?

Discussion in 'ASP .Net' started by Curt_C [MVP], Apr 23, 2004.

  1. Curt_C [MVP]

    Curt_C [MVP] Guest

    Curt_C [MVP], Apr 23, 2004
    #1
    1. Advertising

  2. Curt_C [MVP]

    Bonj Guest

    Nice! Thanks I'll take a look

    "Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
    news:%...
    > Try this
    >

    http://www.aspnetpro.com/NewsletterArticle/2003/08/asp200308bm_l/asp200308bm_l.asp
    >
    > or I used to use this
    > http://www.darkfalz.com/1058
    >
    > --
    > Curt Christianson
    > Owner/Lead Developer, DF-Software
    > Site: http://www.Darkfalz.com
    > Blog: http://blog.Darkfalz.com
    >
    >
    > "RepStat" <> wrote in message
    > news:...
    > > Hi
    > >
    > > What is the best way of displaying a 'please wait...calculating' message

    > to the user, while a long operation, such as database access, is

    occurring,
    > on an ASP.NET page?
    > >
    > >
    > > Thanks a lot

    >
    >
     
    Bonj, Apr 23, 2004
    #2
    1. Advertising

  3. Curt_C [MVP]

    Bonj Guest

    FWIW I've ended up using:

    <%@ Control Language="c#" AutoEventWireup="false"
    Codebehind="ProgIndicator.ascx.cs" Inherits="JSTimer.ProgIndicator"
    TargetSchema="http://schemas.microsoft.com/intellisense/ie5"%>
    <div id="progtext" style="WIDTH: 224px; FONT-FAMILY: Impact; HEIGHT:
    20px"></div>
    <table style="BORDER-RIGHT: medium none; BORDER-TOP: medium none;
    BORDER-LEFT: medium none; BORDER-BOTTOM: medium none"
    cellSpacing="0" cellPadding="0">
    <tr>
    <td id="progcell1" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell2" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell3" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell4" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell5" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell6" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell7" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell8" style="WIDTH: 10px; HEIGHT: 20px"></td>
    <td style="WIDTH: 15px; HEIGHT: 20px"></td>
    <td id="progcell9" style="WIDTH: 10px; HEIGHT: 20px"></td>
    </tr>
    </table>

    with the following JavaScript:
    var dots = 0;

    function ShowWait() {

    if((++dots)>9) dots=1;

    for(var x=1; x<=9; x++) {

    if(x==dots) document.getElementById('progcell'+x).style.backgroundColor =
    'Navy';

    else document.getElementById('progcell'+x).style.backgroundColor =
    'SkyBlue'; }

    }

    function StartShowWait() {

    progtext.style.visibility = 'visible';

    progtext.innerText = 'Please wait - calculating...';

    window.setInterval('ShowWait()',75);

    ShowWait();

    }

    function HideWait(){

    progtext.style.visibility = 'hidden';

    divdisplay.style.visiblity = 'hidden';

    window.clearInterval();

    }



    This javascript just gets emitted using RegisterStartupScript, along with a
    call to the relevant function via the same, doesn't seem

    to work if I embed the JavaScript functions in the page in design mode which
    is what I wanted, however I've got

    another clientside control so I might have it call it as it's the one that
    triggers the long operation anyway

    so it will be able to call this before it does a postback, which is what I
    wanted.



    "Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
    news:%...
    > Try this
    >

    http://www.aspnetpro.com/NewsletterArticle/2003/08/asp200308bm_l/asp200308bm_l.asp
    >
    > or I used to use this
    > http://www.darkfalz.com/1058
    >
    > --
    > Curt Christianson
    > Owner/Lead Developer, DF-Software
    > Site: http://www.Darkfalz.com
    > Blog: http://blog.Darkfalz.com
    >
    >
    > "RepStat" <> wrote in message
    > news:...
    > > Hi
    > >
    > > What is the best way of displaying a 'please wait...calculating' message

    > to the user, while a long operation, such as database access, is

    occurring,
    > on an ASP.NET page?
    > >
    > >
    > > Thanks a lot

    >
    >
     
    Bonj, Apr 24, 2004
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Dmitriy Lapshin [C# / .NET MVP]

    Re: 'Please wait' on long operation?

    Dmitriy Lapshin [C# / .NET MVP], Apr 23, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    433
    Dmitriy Lapshin [C# / .NET MVP]
    Apr 23, 2004
  2. =?Utf-8?B?UG9udGlNYXg=?=

    Long-running task: Show DIV with 'Please wait' message

    =?Utf-8?B?UG9udGlNYXg=?=, Feb 10, 2005, in forum: ASP .Net
    Replies:
    5
    Views:
    4,446
    =?Utf-8?B?ZmFsY29u?=
    Feb 11, 2005
  3. Gary
    Replies:
    1
    Views:
    3,994
    Ryan Stewart
    Jan 16, 2004
  4. mvr
    Replies:
    4
    Views:
    233
    Curt_C [MVP]
    Jan 13, 2004
  5. p byers
    Replies:
    4
    Views:
    748
    p byers
    Dec 20, 2009
Loading...

Share This Page