'End Function' must be preceded by a matching 'Function'
An End Function statement appears in your code with no matching Function procedure definition preceding it.
Error ID: BC30430
To correct this error
Remove the End Function statement if it is redundant.
Supply the missing Function procedure if one is missing.
Move the End Function to the appropriate place in the code.