| 4D v18Progress Stopped | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 
 | 
    4D v18
 Progress Stopped 
         | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Progress Stopped ( id ) -> Function result | ||||||||
| Parameter | Type | Description | ||||||
| id | Longint |   | ID of progress bar | |||||
| Function result | Boolean |   | True = User clicked the Stop button | |||||
The Progress Stopped method returns True when a user clicks on the Stop button of the progress bar designated by the id parameter.
You must call this method to test whether the user clicked the Stop button. The button does not trigger an event itself.
Example of progress bar on a loop:
 $ProgressID:=Progress New // create a new progress bar
  // The progress bar must have a Stop button
 Progress SET BUTTON ENABLED($ProgressID;True)
 For($i;1;100)
  // As long as progress is not stopped...
    If(Not(Progress Stopped($ProgressID)))
       Progress SET TITLE($ProgressID;"Test progress #"+String($ProgressID))
       Progress SET PROGRESS($ProgressID;$i/100)
       Progress SET MESSAGE($ProgressID;String(100*$i/100)+" %")
       (...)
    Else // The user clicks on Stop
       $i:=100 // We exit the loop
    End if
 End for
  // Final closing of progress bar (the Stop button itself does nothing)
 Progress QUIT($ProgressID)
	Product:  4D
	Theme:  Progress bars
	
        
        
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	4D Progress ( 4D v18)
	
	
 Add a comment
Add a comment