use strict; use warnings; use use Win32::TieRegistry ( Delimiter => "/", ArrayValues => 1 ); my $rootkey = "LMachine/Software/Microsoft/Windows NT/CurrentVersion/Winlogon"; $Registry->{"$rootkey//testkey"} = "foobar";