Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Author
Message
ZomBfied
23
Years of Service
User Offline
Joined: 2nd Oct 2002
Location:
Posted: 25th Sep 2003 18:44
Hey how hard would it be to have function-declared static variables?

function myfunction()
static x as integer
x=x+2
endfunction

Now x will continue to increment each time you call the function and not be reset, however it's still local to the function and not affected anywhere else.
CattleRustler
Retired Moderator
22
Years of Service
User Offline
Joined: 8th Aug 2003
Location: case modding at overclock.net
Posted: 25th Sep 2003 19:12
I don't know if that is possible. does dbp support global constants?

-RUST-
IanM
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 25th Sep 2003 20:57
Currently DBPro does not support static local variables, but it's easy enough to simulate them



Global constants are easy ...

Login to post a reply

Server time is: 2026-07-25 07:01:05
Your offset time is: 2026-07-25 07:01:05