It really isn't post-worthy: the function it generates is hardcoded, so you'd have to have Visual Basic to make any use of it.
It is much easier to just edit the code each time, rather than bother integrating a text interpreter.
If anybody wants a custom function, just say, and I'll send you the results.