For Programmers: Free Programming Magazines  


Home > Archive > Clarion > January 2007 > source progress bar









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author source progress bar
ikonjevic

2007-01-07, 6:55 pm

hi, i need help, i make source for progress bar, but it doesnt work, can
anyone correct my code and help me

PROGRAM
MAP
END
INCLUDE('ERRORS.CLW')
Mjesta FILE,DRIVER('TOPSPEED'),NAME('Mjesta.tps'),PRE(Mje)
k_siframje KEY(+Mje:Siframje),PRIMARY
RECORD RECORD
Siframje LONG(6)
Nazivmje STRING(45)
Sifposte LONG(5)
END
END
Progress1 BYTE
PostotakObrade BYTE
ObradjenoSlogova SHORT
SlogovaZaObradu SHORT
Progress WINDOW('Napredak obrade !'),AT(,,395,224),FONT('MS Sans
Serif',8,,),TIMER(100),GRAY,DOUBLE
PROGRESS,USE(Progress1),AT(15,57,350,20)
,RANGE(0,100)
STRING(''),AT(15,115,350,20),USE(?ProgresText),CENTER
BUTTON('&Izlaz'),AT(335,199,55,20),USE(?Close)
END
CODE
Open(Progress)
Display()
Open(Mjesta)
SlogovaZaObradu=RECORDS(Mjesta)
Set(Mjesta)
Accept
Case Event()
Of Event:CloseWindow
Break
Of Event:Timer
?ProgresText{Prop:Text}='0% završeno'
Display(?ProgresText)
Loop
Next(Mjesta)
If Errorcode() Then Break.
ObradjenoSlogova =ObradjenoSlogova + 1
If PostotakObrade < 100
PostotakObrade=(ObradjenoSlogova/SlogovaZaObradu)*100
If PostotakObrade > 100
PostotakObrade=100
End
If PostotakObrade<>Progress1 Then
Progress1=PostotakObrade

? ProgresText{Prop:Text}=Format(PostotakOb
rade,@N3)&'% završeno'
Display(?ProgresText)
End
End
Display(?Progress1)
End
End
End
Post(Event:CloseWindow)



thanks

ivica

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2009 codecomments.com