Date:  01/11/2015 04:44:23 AM Msg ID:  004767
From:  Joël Thread:  004757
Subject:  Re: ProgressBar
Hi 
 
The download link below returns a 404 error
 
Kind regards
Joël.
Sent by FoxWeb Support on 12/27/2014 10:52:00 AM:
You can download the files from here. Note that there are a lot of modern progress bar components that are more powerful and versatile than this. The demo was created to illustrate how a running server-side script could control a progress bar on the browser side.
FoxWeb Support Team
support@foxweb.com email
Sent by Ali Koumaiha on 12/27/2014 06:53:19 AM:
How can I see the source code for the progressbar demo?
 
Sent by FoxWeb Support on 12/27/2014 12:46:35 AM:
It's hard to tell what's wrong just by looking at the code. Does the demo on our server work for you? I just tried with multiple browsers and it works fine.
 
Have you tried debugging with the developer tools? Press F12 and look for javascript errors.
 
If the page is accessible over the Internet, please post the URL too. 
FoxWeb Support Team
support@foxweb.com email
Sent by yoon deokman on 12/26/2014 07:20:25 PM:
Hi!
Right, Sorry! 
The chrome bars appear progress bar, explorer not in the running. 
Why don't you try to explain it to me.
Thanks  
Sent by FoxWeb Support on 12/26/2014 10:46:47 AM:
What are the problems you are referring to? You can't just paste some code and expect people to run it to determine the problem -- especially not when this code has dependencies on your own data tables, which makes it impossible to run. Please describe the exact nature of the problem and steps to reproduce. 
FoxWeb Support Team
support@foxweb.com email
Sent by yoon deokman on 12/26/2014 04:40:19 AM:
 Hi!
Could you help me with this problems?
 
<html>
<head>
<%
M.StartTime = SECONDS()
Response.Write('<style>' + CRLF + FILETOSTR('ProgressBar.css') + CRLF + '</style>' + CRLF)
Response.Write('<script language="JavaScript">' + FILETOSTR('ProgressBar.js') + CRLF + '</script>' + CRLF)
%>

<div id="progressOuterDiv"></div>
<script language="JavaScript">
var progressBar = new cProgressBar();
progressBar.init();
progressBar.show(true);
</script>
<%
M.TotalSteps = 30
FOR i = 1 TO M.TotalSteps
UpdateProgressBar(M.i / M.TotalSteps * 100, 'Completed step ' + Server.ToString(M.i) + ' of ' + Server.ToString(M.TotalSteps))
* Some time passes...
WAIT '' TIMEOUT .5
NEXT
%>
<script language="JavaScript">progressBar.show(false);</script>
<p align="left"><font face="Verdana"><span style="font-size:9pt;">Thanks for your patience</span></font></p>

</head>
<body>

<%
set date ansi
set excl off
set dele on

if !used("ydg")
sele 0
USE ydg
endif

IF request.FORMCOUNT()>0
M.STYPE=request.FORM('STYPE')
M.SKEY=request.FORM('SKEY')
endif

sele ydg
do case
case m.stype='1'
sele ydg
set filt to at(allt(upper(m.skey)),upper(name))>0
COUNT TO nVal
        M.MESSAGE="["+ALLTRIM(STR(nVal))+"] Results for ["+M.SKEY+"] in Name"
case m.stype='2'
sele ydg
set filt to at(allt(upper(m.skey)),upper(section))>0
COUNT TO nVal
        M.MESSAGE="["+ALLTRIM(STR(nVal))+"] Results for ["+M.SKEY+"] in Section"
endcase
%>
    <tr>
        <td width="379" align="center">
            <p align="right"><%=m.message%></p>
        </td>
    </tr>

<TABLE cellSpacing=0 borderColorDark=white cellPadding=2 width="120" 
<borderColorLight=silver align="center" style="border-collapse:collapse;" height="18">
<TBODY>
   <TR>
        <td> Dept_no </td> 
        <td> Section </td>  
   </TR> 
<%
sele ydg
go top
scan WHILE !EOF()
if Lenc(allt(ydg.depart_no)) > 100 then
v_depart_no= Leftc(depart_no,100) + "..."
else 
v_depart_no= allt(ydg.depart_no)
endif
  M.REC_NO=ALLT(STR(RECNO()))
%>                                
   <TR>
        <td><%=Dept_no%></td> 
        <td><%=section%></td>  
   </TR> 
      
<%
  endscan
%>
</table>

<%
PROCEDURE UpdateProgressBar
LPARAMETERS PercentComplete, StatusText
IF (SECONDS() - StartTime) + 5 >= Server.ScriptTimeout
Server.AddScriptTimeout(10)
ENDIF

IF TYPE('M.StatusText') <> 'C'
Response.Write([<script language="JavaScript">progressBar.update(] + Server.ToString(M.PercentComplete) + [);</script>] + CRLF)
ELSE
Response.Write([<script language="JavaScript">progressBar.update(] + Server.ToString(M.PercentComplete) + [, '] + M.StatusText + [');</script>] + CRLF)
ENDIF
Response.Flush
ENDPROC
%>
</body>
</html>
 
Thank you very much