Gossamer Forum
Home : General : Perl Programming :

Using ENV to set a var

Quote Reply
Using ENV to set a var
Hi,

Im trying to set a varaible in DOS from a perl script.
But using system, `` or ENV doen't work.
I used the ENV but that only stays for the duration of the perl sript. Im looking
for something more perm or at least until my DOS Batch file finishs to execute.

Any help would be great.

Thanks in Advance.
Quote Reply
Re: [llccoo] Using ENV to set a var In reply to
To do it with Perl you're probably going to need to use Win32::TieRegistry registry module to manipulate the registry. Look at the HKEY_CURRENT_USER->Environment key.

Have you tried setting the ENV var in your batch file instead?

~Charlie
Quote Reply
Re: [Chaz] Using ENV to set a var In reply to
Yes thats what i ended up looking into that win32 stuff

Thanks. =)