TutPutenv


Name

TutPutenv — set a SmartSockets environment variable

Synopsis

T_BOOL TutPutenv(name_and_value) 
T_STR name_and_value; 

Arguments

name_and_value — both the name and value to be put into the environment, separated by an equal sign (=)

Return Values

TRUE if the environment was successfully updated, FALSE otherwise.

Diagnostics

None

Description

TutPutenv puts a value into the environment. The environment is a list of name/value pairs that is set by the operating system for each process. The parameter name_and_value is a string that has both the name of the environment variable and value of the environment, separated by an equal sign (=). For example, to set YOUR_ENV_VAR to something, use this:

TutPutenv("YOUR_ENV_VAR=something") 

The environment only effects the currently running SmartSockets process.

On Windows, TutPutenv puts the value into the runtime associated with the SmartSockets libraries, which may be different that the runtime that the application is running in.

Caution

None

See Also

TutGetenv

Examples

This example puts the value of RTHOME into the environment:

if (!TutPutenv("RTHOME=c:\\SmartSockets")) { 
  /* error */ 
} 

TIBCO SmartSockets™ Utilities
Software Release 6.8, July 2006
Copyright © TIBCO Software Inc. All rights reserved
www.tibco.com