How to know if a custom indicator is available

 
Hello everyone.
Indicator handles do not exist in metatrader4. So how do you make sure if indicator is available and iCustom is returning a valid number?
 
If indicators do not exists you will see errors into Expert logs.

Then you can easily check the returned value for validity, value should be not 0, nor EMPTY_VALUE nor WRONG_VALUE, but it also depends on the used indicator and how was it coded...

 
ResetLastError, call iCustom, call GetLastError and see if the call failed.