Domino Code Fragment

Code Name*
Percent Complete in script
Date*
04/29/2024
Source (or email address if you prefer)*
Rlatulippe@romac.com
IP address:.3.22.249.158
Description*
Type*
LotusScript
Categories*
(Misc)
Implementation:
Required Client:
Server:
Limitations:
Comments:
Files/Graphics attachments (if applicable): Code:
Sub Initialize
Print PercentComplete(30 , CurrentRecord , NotesDocumentCollection.Count)
End Sub

Function PercentComplete(FTGDefault As Integer, FTGCurrent As Double, FTGTotal As Double) As String
%REM
Written by: Jared Knapp
Company: Franklin Templeton Group
Department: IS&T
Date: 2/27/97
Purpose: Displays a percent complete progress indicator
in the print area at the bottom of users screen.
Calls: NewIndicator(),
%END REM
Dim FTGLength As Integer
Dim FTGCount As Integer
PercentComplete = NewIndicator(FTGDefault)
FTGLength = (FTGCurrent*FTGDefault)/FTGTotal
If FTGlength >0 Then
For FTGcount = 2 To FTGlength +1
Mid( PercentComplete , FTGCount, 1) = Chr(127)
Next FTGcount
End If
Mid (PercentComplete,FTGDefault + 4,4)=Cstr(Cint((FTGCurrent/FTGTotal)*100)) + "%"
End Function

Function NewIndicator(FTGDefault As Integer) As String
%REM
Written by: Jared Knapp
Company: Franklin Templeton Group
Department: IS&T
Date: 2/27/97
Purpose: Used by UpdateIndicator to Create a Blank Progress Indicator
%END REM
Dim FTGCount As Integer
NewIndicator = Chr(127)
For FTGcount = 1 To FTGDefault
NewIndicator = NewIndicator + "-"
Next FTGCount
NewIndicator = NewIndicator + Chr(127) + " 0% Complete"
End Function