DatStat Illume 4.5 SDK Class Reference

HookContext.SetResponseData Method 

Sets the value of a survey variable identified by variableName to the responseValue provided.

public bool SetResponseData(
   String variableName,
   Object responseValue
);

Parameters

variableName
The friendly name of the survey variable to set.
responseValue
An Object representing a value of the proper type to set as a response.

Return Value

If there is an error while trying to set the value of the response, false will be returned. Otherwise, true will be returned.

Remarks

At times it may be desirable to set the value of hidden survey variables (e.g. preloads) and maybe even visible survey variables/questions. Since DatStat Illume is a strongly typed system, it is up to the developer to ensure that the type of the object being provided by responseValue is correct for the variable specified by variableName. Always check for a return value of true to ensure that the response was set successfully.

See Also

HookContext Class | DatStat.Collector Namespace