| 
                    
 This is the legacy 4D documentation web site. Documentations are progressively being moved to developer.4d.com  | 
            |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
                 
                
  | 
                
					
                    
                         
    4D v20.6
 
System folder 
                                
                                
        
 | 
                ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| System folder {( type )} -> Function result | ||||||||
| Parameter | Type | Description | ||||||
| type | Longint | 
             
         | 
        Type of system folder | |||||
| Function result | String | 
             
         | 
        Pathname to a system folder | |||||
The System folder command returns the pathname to a particular folder of the operating system or to the active Windows or macOS System folder itself.
You pass in the optional type parameter a value indicating the type of system folder. 4D provides you with the following predefined constants, placed in the “System Folder” theme:
| Constant | Type | Value | Comment | 
| Applications or program files | Longint | 16 | |
| Desktop | Longint | 15 | |
| Documents folder | Longint | 17 | "Documents" folder of user | 
| Favorites Win | Longint | 14 | |
| Fonts | Longint | 1 | |
| Home folder | Longint | 18 | Current home folder of the user (usually "/Users/<username>/")  | 
		
| Start menu Win_all | Longint | 8 | |
| Start menu Win_user | Longint | 9 | |
| Startup Win_all | Longint | 4 | |
| Startup Win_user | Longint | 5 | |
| System | Longint | 0 | |
| System Win | Longint | 12 | |
| System32 Win | Longint | 13 | |
| User preferences_all | Longint | 2 | |
| User preferences_user | Longint | 3 | 
Notes:
If you omit the type parameter, the function will return the pathname to active System folder (= constant System).
	Product:  4D
	Theme:  System Environment
	Number:  
        487
        
        
        
	
	Modified:  4D v11 SQL Release 4 
	Modified:  4D v13
	Modified:  4D v19 R8
	
	4D Language Reference ( 4D v20)
	
	4D Language Reference ( 4D v20.1)
	
	
	4D Language Reference ( 4D v20.2)
	
	4D Language Reference ( 4D v20.3)
	
	4D Language Reference ( 4D v20.4)
	
	4D Language Reference ( 4D v20.5)
	4D Language Reference ( 4D v20.6)
	
	
	
Add a comment