in reply to Re^2: windows shortcut and args
in thread windows shortcut and args

What does "assoc .blt" say?

Replies are listed 'Best First'.
Re^4: windows shortcut and args
by enrgyxprt (Acolyte) on Jan 16, 2017 at 02:09 UTC

    Almost had a Doh! moment... but after </p.

    C:\WINDOWS\system32>assoc .blt=C:\Perl Builder2\RemLaunch.pl .blt=C:\Perl Builder2\RemLaunch.pl
    I still get "This app cant run on your pc"...

      how about

      ftype PerlRemlaunch=c:\perl64\bin\perl5.16.3.exe "C:\Perl Builder2\Rem +Launch.pl" "%1" assoc .blt=PerlRemlaunch
      or maybe
      assoc .blt=c:\perl64\bin\perl5.16.3.exe C:\Perl Builder2\RemLaunch.pl +"%1"
      I think you were expecting a level of redirection that isnt there. "C:\Perl Builder2\RemLaunch.pl" isnt an executable type (exe,com,...)

        Nope... May be time to use a batch file in between the .blt and my launcher ...

        I think you were expecting a level of redirection that isnt there. "C:\Perl Builder2\RemLaunch.pl" isnt an executable type (exe,com,...)

        Hi,

        It is something that needs checking

        On windows an "executable type" is just another registry entry -- or %PATHEXT% entry -- its possible to break windows by removing .exe/.dll... from said list

        See %PATHEXT%, and chain of links about HKLM\Software\Classes\.exe HKLM\Software\Classes\exefile

      Hi,

      Why do you expect that to work?

      The path has spaces but is not quoted

      There is no wildcard thing for @ARGV

      Perl.exe isn't mentioned, and I only mention this because I've no idea how many levels of indirection ftype/assoc like to expand in what they consider an executable... and you'll have to do the checking so you should know what to do if quoting the full path to the .pl doesn't work

        tied quoting like

         assoc .blt="C:\Perl Builder2\RemLaunch.pl" Ty anyway..