How about exposing the UDF's return values directly as COM properties ?