Eyeon:Script/Reference/Applications/Fusion/Classes/Fusion/GetEnv
From VFXPedia
Contents |
Fusion : GetEnv
Arguments
GetEnv( envname )
- envname(required, string)
the name of the process environment variable to retrieve.
Returns
The value of the environment variable specified as an argument, or nil if that variable does not exist.
Remarks
This function returns the value of an environment variable on the machine running Fusion. This function is identical to the global ///os.getenv]]() function, except that it runs in the context of the Fusion Interface object, so if the Fusion Interface object points to a remote copy of Fusion the environment variable will come from the remote machine.
Requirements
- eyeonScript 5.0
- Fusion 5.0
Examples
-- this in-tool script should be placed in the -- script tab of a text+ tool local comp = fusiong:GetCurrentComp() local x = "Artist:"..fusion:GetEnv("USERNAME") ..
"\nFile : ".. composition:GetAttrs().COMPS_Name.. "\nFrame :".. composition.CurrentTime
Text1.StyledText = x
-- this command line script fragment -- returns the location of the Windows -- operating system on a remote machine -- and adds the Font directory to the end remote_fusion = Fusion("192.168.1.100") font_dir = remote_fusion:GetEnv("SYSTEMROOT") .."\\Font"
Tips for GetEnv (edit)
EyeonTips:Script/Reference/Applications/Fusion/Classes/Fusion/GetEnv