← Back to context

Comment by jodrellblank

13 years ago

Oh come on, spreadsheets aren't that bad. Excel has had named ranges forever, and they can be scoped to the worksheet so they aren't completely global.

http://office.microsoft.com/en-us/excel-help/define-and-use-...

And functions can be VBA so the state of those global variables isn't the only way for functions to talk to each other. e.g.

    Dim x As Integer

    Function setx(n)
        x = n
        setx = 1
    End Function

    Function getx()
        getx = x
    End Function

and then you can put =setx(200) in one cell and =getx() in another. It is hard to look at the whole thing at once, but when do you need to do that?