Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Re: Sharing Global variables between scripts

by TASdvlper (Monk)
on Apr 16, 2004 at 22:28 UTC ( [id://345895]=note: print w/replies, xml ) Need Help??


in reply to Re: Sharing Global variables between scripts
in thread Sharing Global variables between scripts

I'm a little confused, so how do I resolve the problem (if I can) ? Thanks in advance. I don't normally use global variables so I'm a little new to this.
  • Comment on Re: Re: Sharing Global variables between scripts

Replies are listed 'Best First'.
Re: Re: Re: Sharing Global variables between scripts
by tilly (Archbishop) on Apr 16, 2004 at 23:07 UTC
    You move the package declaration to the top of your script. That will remove the error message that you are getting.

    Note that this will not (as pointed out by gjb) magically cause data which exists in one process to be visible in another.

    Also note that global variables in general should be used with caution. You want to limit how many you have, and you want to get maximal value from each one.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://345895]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (5)
As of 2024-04-25 06:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found