Working in a classic VB6 app, crazy comments by the thousands.
Example:
If garrFilePaths(i).FilePath = "" Then
'do nothing
Else
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If
Working in a classic VB6 app, crazy comments by the thousands.
Example:
If garrFilePaths(i).FilePath = "" Then
'do nothing
Else
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If
Refactor so it makes sense. Not a lot to "handle", just remove the cruft so you don't have to spend brain-cycles on it.
Perhaps talk to the developer who wrote it, and/or work on guiding documents (coding standards) to help people do the right thing.
Restructure the code and delete them.
If Not (garrFilePaths(i).FilePath = "") Then
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If
This often works for comments that do make sense too.
If garrFilePaths(i).FilePath = "" Then
'do nothing 'fool
Else
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If