Tuesday, 18 November 2014

In the absence of interesting content, a filler piece

We don't always get to write good code: sometimes we have the job of thanking someone for their contribution, telling them truthfully and cheerfully: "No, really: it couldn't *possibly* be improved!", and gaffer-taping it together with comprehensible variable declarations and a bit of code-readability work.

Here's a function that will help you with that:
'
Public Function f(Optional Filler As Variant = "") As Double
Application.Volatile False

' Function always returns zero - its only purpose is to 'pad out' expressions for readability
' An option to suppress VBA's habit of excising 'unnecessary' whitespace would be more useful

f = 0

' Coding Notes:
'
' If it is ever necessary for you to use this, leave the following note for your colleagues:
'
'          "There is no hope for us. I am Bricking Up The House From Within."
'
' Code Enhancement: leave an acknowledgement in the code, naming someone you *really* dislike

End Function
Feel free to *not* acknowledge my contribution if you reuse this code.

I do have an acknowledgement for my betters here: the apocalyptic phrase 'We Are Bricking Up The House From Within' originates from Adrian Bott, well known and much-esteemed as @Cavalorn.

He's not a developer: he's a published author of Fantasy and Horror.

No comments:

Post a Comment