You should use iReleaseLogger.
You don't need to remove the logging code. Only remove the library and the two lines related to ReleaseLogger. You can use conditional compilation for this:
#If Not(Store) Then
Dim rl As ReleaseLogger
rl.Initialize("192.168.0.6", 54323)
#End If
Press Ctrl + B to add the STORE symbol to the "store" build configuration.