# fsVarsCustomSimdVarGet {{< callout context="note" title="NOTE" icon="outline/bulb" >}} Deprecated. Use `fsVarsIVarGet, `[fsVarsOVarGet](fsvarsovarget/)` or `[fsVarsZVarGet](fsvarszvarget/)instead. {{< /callout >}} The **fsVarsCustomSimVarGet** function can be used to get the value of a specific Custom SimVar.   ##### Syntax ``` wasm FsVarError fsVarsCustimSimVarGet( FsCustomSimVardId varId, FsUnitId unitId, double* result ); ```   ##### Parameters {{< table-wrapper >}} | Parameters | Description | |------------|-------------------------------------------------------------------------| | `varId` | The ID of a custom simvar. | | `unitId` | The ID of an unit (found using [fsVarsGetUnitId](fsvarsgetunitid/)). | | `result` | The value that will receive the value of the CustomSimVar. | {{< /table-wrapper >}}   ##### Return Values The function returns a `FsVarError`, 0 means there is no error. In that case, the value of the named variable has been set in `result`.   ##### Example ``` wasm FsUnitId unitId = fsVarsGetUnitId("DEGREES"); FsCustomSimVarId varId = fsVarsRegisterCustomSimVar("TOTO", nullptr, FsSimCustomSimVarScopeSim); double result = 0; if (fsVarsCustomSimVarGet(varId , unitId, &result) == FS_VAR_ERROR_NONE) { // valid } else { // error } ```