2020-06-30 12:47:33 +02:00
|
|
|
include::../description.adoc[]
|
|
|
|
|
|
|
|
== Noncompliant Code Example
|
|
|
|
|
|
|
|
With an indent size of 2:
|
2020-06-30 14:49:38 +02:00
|
|
|
|
2020-06-30 12:47:33 +02:00
|
|
|
----
|
|
|
|
Public Sub OutputObject(oOutput As Object)
|
|
|
|
Set oObject = oOutput
|
|
|
|
|
|
|
|
If TypeOf oObject Is Form Then
|
|
|
|
oObject.Cls
|
|
|
|
ElseIf TypeOf oObject Is PictureBox Then
|
|
|
|
oObject.Cls
|
|
|
|
ElseIf TypeOf oObject Is ListBox Then
|
|
|
|
oObject.Clear
|
|
|
|
End If
|
|
|
|
End Sub
|
|
|
|
----
|
|
|
|
|
|
|
|
== Compliant Solution
|
|
|
|
|
|
|
|
----
|
|
|
|
Public Sub OutputObject(oOutput As Object)
|
|
|
|
Set oObject = oOutput
|
|
|
|
|
|
|
|
If TypeOf oObject Is Form Then
|
|
|
|
oObject.Cls
|
|
|
|
ElseIf TypeOf oObject Is PictureBox Then
|
|
|
|
oObject.Cls
|
|
|
|
ElseIf TypeOf oObject Is ListBox Then
|
|
|
|
oObject.Clear
|
|
|
|
End If
|
|
|
|
End Sub
|
|
|
|
----
|
2021-06-02 20:44:38 +02:00
|
|
|
|
2021-06-03 09:05:38 +02:00
|
|
|
ifdef::env-github,rspecator-view[]
|
2021-06-08 15:52:13 +02:00
|
|
|
'''
|
2021-06-02 20:44:38 +02:00
|
|
|
== Comments And Links
|
|
|
|
(visible only on this page)
|
|
|
|
|
|
|
|
include::../comments-and-links.adoc[]
|
2021-06-03 09:05:38 +02:00
|
|
|
endif::env-github,rspecator-view[]
|