View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Jac Tremblay[_4_] Jac Tremblay[_4_] is offline
external usenet poster
 
Posts: 99
Default Function to return two values

Hi,
Is it possible to create a function that will return two values, a boolean
and a string?
I need to exit the main procedure if the data checked by the function is not
valid and also display a message according to the particular validation.
For example:
If Not DataIsValid Then
Msgbox strErrorMsg ' Returned from the function
Exit Sub
end IF
Thanks
--
Jac Tremblay