If you need a variable across functions, use a global variable.
Or you could do what most people do, and opt to pass the variable to the function you need it in. Pass it directly if you don't need to modify it, otherwise pass a pointer to it. It's seldom a better choice to use a global variable instead of what I've mentioned.

Quzah.