How to return a result from a VBA function

How do I return a result from a function?

For example:

Public Function test() As Integer
    return 1
End Function

This gives a compile error.

How do I make this function return an integer?

4 Answers
4

Leave a Comment