PDA

View Full Version : I can't get globals to be global


svintaj
11-18-2003, 08:19 PM
Do you know what's wrong with this script? :shrug:


global string $TestString = "Hello";

TestProc();

global proc TestProc(){
print ( $TestString );
}


I get this error:
Error: "$TestString" is an undeclared variable.

Thanks/ Svante

brubin
11-18-2003, 10:21 PM
that's easy: try including the bold line i added.

HIH
s.


global string $TestString = "Hello";

TestProc();

global proc TestProc(){
global string $TestString ;
print ( $TestString );
}

svintaj
11-19-2003, 08:32 AM
Great :thumbsup:

Thanks / Svante

CGTalk Moderation
01-16-2006, 05:00 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.