?
Solved

Get user environment variable in perl

Posted on 2008-10-07
5
Medium Priority
?
1,353 Views
Last Modified: 2012-08-14
Hi,
I was able to get all my SYSTEM path variable paths through $ENV{'PATH'};
How can I get USER environment variable paths as well Perl's path variable?
0
Comment
Question by:nopopo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
5 Comments
 
LVL 48

Accepted Solution

by:
Tintin earned 1000 total points
ID: 22662857
You can access an environment variable with

$ENV{'environment-variable-name'}
0
 
LVL 39

Assisted Solution

by:Adam314
Adam314 earned 1000 total points
ID: 22663591
The only difference between the SYSTEM and USER environment variables is the SYSTEM ones are set for everybody, and the USER ones are set by user.

The $ENV{variable} will give you both SYSTEM and USER environment variables.
0
 
LVL 48

Expert Comment

by:Tintin
ID: 24470165
recommend points split.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Configuring Remote Assistance for use with SCCM
When asking a question in a forum or creating documentation, screenshots are vital tools that can convey a lot more information and save you and your reader a lot of time
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question