> A while ago I saw a Progress Bar when I was creating a new table via SQL using a Select .. FROM ... INTO routine.
Hi Bryan!
If the table or a cursor is created using SELECT... FROM ... INTO, you can somehow do your own custom bar to show its progress.
Local loObjForm
loObjForm = Createobject('SampleForm')
loObjForm.Show(1)
Define Class SampleForm As Form
AutoCenter = .T.
Height = 100
Width = 400
Add Object Container1 As Container With Left = 10, ;
WIDTH = 380, SpecialEffect = 1, Top = 20, Height = 15
Add Object Shape1 As Shape With Left = 10, Width = 0, ;
TOP = 20, Height = 14, FillColor = Rgb(111,111,111), FillStyle = 0
Procedure Load
*-- Opens products table from VFP9 Home Dir, if the said table doesn't exist please modify
Use 'c:\PROGRAM FILES\microsoft VISUAL FOXPRO 9\samples\DATA\products' In 0
Endproc
Procedure Activate
Local lnCount
lnCount = Reccount('Products')
Select *, This.MoveBar(m.lnCount,Recno()) From Products Into Cursor NewProducts
Browse Normal
Endproc
Procedure MoveBar
Lparameters lnParam1, lnParam2
Thisform.Shape1.Width = Thisform.Container1.Width * (lnParam2/lnParam1)
Wait '' Timeout .1 && Added just to slow down its growth so we can see, better removed to speed up the process
Endproc
Enddefine
(coffee)
DeepLogic Computers & Software / Acer Lending Investor