1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49
sub windows_create_shortcut { my $file=shift; my $path=shift; my $args=shift; debug(2, "entering windows_create_shortcut\n"); my $link = Win32::Shortcut->new(); if (lc(substr($file, length($file)-4)) ne ".lnk" ) { # print ".lnk added to shortcut $file\n"; $file .= ".lnk"; } debug(3, "creating shortcut '$file' to '$path' '$args'\n"); $link->{'File'} = $file; $link->{'Path'} = $path; $link->{'Arguments'} = $args; $link->{'ShowCmd'} = 1; $link->Save; $link->Close; debug(2, "leaving windows_create_shortcut\n"); } und.... # taf windows_create_shortcut( $desktop."\\$sid\\c taf (tail -f $alert_file_name)", $dbaconf->{SID}->{$sid}->{'DBA_COMMON'}."\\scripts\\dosbox", "$sid taf"); # ta200 windows_create_shortcut( $desktop."\\$sid\\c ta200 (tail -200 $alert_file_name)", $dbaconf->{SID}->{$sid}->{'DBA_COMMON'}."\\scripts\\dosbox", "$sid ta200"); # via windows_create_shortcut( $desktop."\\$sid\\c via (notepad $alert_file_name)", $dbaconf->{SID}->{$sid}->{'DBA_COMMON'}."\\scripts\\dosbox", "$sid via"); # vio windows_create_shortcut( $desktop."\\$sid\\c vio (notepad init$sid.ora)", "notepad", $dbaconf->{SID}->{$sid}->{'DBA_ENTITY'}."\\pfile\\init$sid.ora"); # dosbox with env windows_create_shortcut( $desktop."\\$sid\\c dosbox (DOS_box with environment)", $dbaconf->{SID}->{$sid}->{'DBA_COMMON'}."\\scripts\\dosbox", "$sid cmd");
2012-03-05T22:41:41 pktmGeht das event. mit runas?