You are correct that functions return a value, whereas subs do not, but it
does not follow that you should use a sub if you do not plan to return a
value.
There are other valid reasons to choose a function, e.g. so that you can use
it directly in one of the event properties (which accept functions, not
subs).
Ultimately it comes down to a matter of style. I almost never write a sub
(other than the built-in event procedures), and generally return something -
True on success if nothing else is obvious. Even though the calling code
will probably ignore the return value, it can help with debugging, and you
may want to know if the thing worked one day.
Simple example: if you were writing something to open a report, would you
use:
Sub OpenTheReport()
give error 2501 if it failed? Or would it be a better interface to code:
Function OpenTheReport() As Boolean
Then if the user does not care if it opened or not, they use:
Call OpenTheReport
and if they want to take action depending on whether it opened, the use:
If OpenTheReport() Then ...