Hi,
I'm writing a script that reads a .reg file and creates a file with the
Installshield functions needed to write the registry entries from the .reg
file.
I have come across a problem looking for the @ sign. If I use ($_ =
~/\@=".*"/) or ($_ = ~/@=".*"/)  - in an if statement it picks up every
line.

The lines I'm interested in are of this format: @="testing". I split these
around the = and put the values into an array (which always contains
4294967295)

If this doesn't make sense here's the code I'm using:

        } elsif ($_ = ~/\@=".*"/) {
                #its the default string
                #print "$_\n";

                @values = split /=/, $_;                #get the name and
value

                print "@values\n";

                $name = "\"\"";                                 #assign the
name to the default value (nothing)

                $value = $values[1];

                chomp ($value);                                 #chop this
to remove the trailing \n

                $type = "REGDB_STRING";                 #string type
        }

Thanks,
Matt

> Matt Thompson
> AspenTech
> process. to the power of e.
> Cambridge, UK
> mailto:[EMAIL PROTECTED]
> http://www.aspentech.com
> +44 1223 819777
> 
_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/activeperl

Reply via email to