RosettaCodeData/Task/Flow-control-structures/Visual-Basic-.NET/flow-control-structures-5.visual

12 lines
285 B
Text
Raw Permalink Normal View History

2013-04-10 22:43:41 -07:00
Function Foo3()
Foo3 = CalculateValue()
If Not MoreWorkNeeded() Then Exit Function
Foo3 = CalculateAnotherValue()
End Function
Function Foo4()
Dim result = CalculateValue()
If Not MoreWorkNeeded() Then Return result
Return CalculateAnotherValue()
End Function