Vb6 如何处理荒谬的评论?
在一个经典的VB6应用程序中工作,成千上万的疯狂评论 例如:Vb6 如何处理荒谬的评论?,vb6,comments,Vb6,Comments,在一个经典的VB6应用程序中工作,成千上万的疯狂评论 例如: If garrFilePaths(i).FilePath = "" Then<br> 'do nothing Else MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle End If 如果文件路径(i).FilePath=“”则 “什么也不做 其他的 MsgBo
If garrFilePaths(i).FilePath = "" Then<br>
'do nothing
Else
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If
如果文件路径(i).FilePath=“”则
“什么也不做
其他的
MsgBox“未找到文件(“&GarrFilePath(i).FilePath&”),vbOKOnly,gcstrMessageBoxTitle
如果结束
重构,使其有意义。没有太多需要“处理”的东西,只需去除积垢,这样你就不必在上面花费大脑周期
也许可以与编写它的开发人员交谈,和/或编写指导文档(编码标准),以帮助人们做正确的事情。重构,使其有意义。没有太多需要“处理”的东西,只需去除积垢,这样你就不必在上面花费大脑周期
也许可以与编写代码的开发人员交谈,和/或编写指导文档(编码标准),以帮助人们做正确的事情。重新构造代码并删除它们
If Not (garrFilePaths(i).FilePath = "") Then
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If
这通常也适用于有意义的注释。重新构造代码并删除它们
If Not (garrFilePaths(i).FilePath = "") Then
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If
If garrFilePaths(i).FilePath = "" Then
'do nothing 'fool
Else
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If
这通常也适用于有意义的评论。问题又是什么?问题又是什么?我已经有一段时间没有做Basic了,但我认为这可能是GarrFilePath(I).FilePath”“。@legoscia:是的,我刚刚确认,这将是等效的语法。我花了很长时间才弄明白如何搜索
:)这不是等效条件,特别是如果使用了“错误恢复下一步”时的。@wqw:这与问题中的代码如何不等效?我做Basic已经有一段时间了,但我认为这可能是GarrFilePath(I.FilePath)。@legoscia:是的,我刚刚确认,这将是等效语法。我花了很长时间才弄明白如何搜索
:)这不是等效条件,特别是如果使用了“错误恢复下一步”时的。@wqw:这怎么与问题中的代码不等效?
If garrFilePaths(i).FilePath = "" Then
'do nothing 'fool
Else
MsgBox "File Not Found (" & garrFilePaths(i).FilePath & ")", vbOKOnly, gcstrMessageBoxTitle
End If