VB6 Indenter is a free program, which indents VB6 code properly. You copy your VB code to the clipboard, click a button, then paste it back. Here is an example:
Input |
Output |
'Example ------------------------
Private Sub demo()
Dim n As Integer
Dim s As String
For n = 1 to 10
If n = 2 Then
s = ""
ElseIf n = 4 Then
s = "test"
Else
s = "any"
End If
s = "Here is a split line+ _
"with this" _
"and this"
Next
End Sub
|
'Example ------------------------
Private Sub demo() '------- demo -------
Dim n As Integer
Dim s As String
For n = 1 to 10
If n = 2 Then
s = ""
ElseIf n = 4 Then
s = "test"
Else
s = "any"
End If
s = "Here is a split line+ _
"with this" _
"and this"
Next
End Sub
|
Download
Download VB6 Indenter
as an exe file (350Kb) or
as zip file (186 Kb)
The source code (in Delphi) is also available - mail me.