Could someone help me with the correct syntax? To add a simple "string" to the path variable? This is the example code from the moduls web-page:

Win32::Env::Path
use Win32::Env::Path; my $path = Win32::Env::Path->new( name => 'PATH', ); $path->add('C:\\strawberry');
Or Should i use a different Update: module, script, method whatever?
Why: I have to deal with a local app (which executable is on a mapped network ressource) which needs to be in the path of all users. I want to automate this, cause it occurs on every new machine which joins the Windows 2003 domain ... I hope it is easier now to understand what i want? I could of course use something like autoit autoit to do it but i think it should be possible otherwise?
/Update
Solved using the script:
CleanPath
Special Thanks to tye
Thanks MH

In reply to Trying to use [cpan://Win32::Env::Path] to change Windows Path Variable? by matze77

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.