I am in this position again with warning that I cant get rid of, Here is the code:

Public Function POPErrors(ByVal strMsg As String)

        MsgBox("POP3 ERROR - " & vbNewLine & strMsg, MsgBoxStyle.Critical)

End Function

Here is the warning:
Function 'POPErrors' doesn't return a value on all code paths. A null reference exception could
occur at run time when the result is used.

What does that mean?
And how do I get rid of it.

could you give me an example
thanks

Actually I got it

I put in POPerrors = ""

in the function and that got rid of it.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.