| 4D View v15PV SET CELL VARIABLE | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 
 | 
    4D View v15
 PV SET CELL VARIABLE 
         | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| PV SET CELL VARIABLE ( area ; column ; row ; variable ) | ||||||||
| Parameter | Type | Description | ||||||
| area | Longint |   | 4D View area | |||||
| column | Longint |   | Cell column number | |||||
| row | Longint |   | Cell row number | |||||
| variable | String |   | Variable name | |||||
The PV SET CELL VARIABLE command links the cell set by column and row to a variable. Any modifications to the cell content will affect the variable and vice-versa.
The following form method displays the current time in cell C3 using the vTime variable. This variable is updated each second, such that the cell acts as a clock:
 C_TIME(vTime) `Variable receiving displayed time
 
 Case of
    :(Form event=On Load)
       If(PV Get cell variable(Area;3;3)="") `Still no variable associated with C3
          PV SET CELL VARIABLE(Area;3;3;"vTime") `Associate the vTime variable
       End if
       SET TIMER(60) `Every second
 
    :(Form event=On Timer)
       vTime:=Current time
 End case
									PV ADD DYNAMIC ARRAYS
									
									PV Get cell value type
									
									PV Get cell variable
									
									PV SET CELL FIELD
									
	Product:  4D View
	Theme:  PV Cell value
	Number:  
        15919
        
        
        
	
	Created:  4D View 6.8
	
	
	
	
	
	
	
	
	4D View Language ( 4D View v15)
	
	
	
	
	
	
	
 Add a comment
Add a comment