Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^2: Win7, ASSOCiation , and @ARGV

by ww (Bishop)
on Mar 14, 2012 at 17:14 UTC ( #959627=note: print w/ replies, xml ) Need Help??


in reply to Re: Win7, ASSOCiation , and @ARGV
in thread Win7, ASSOCiation , and @ARGV

More puzzlement (perhaps because when we play in the registery, we're beyond my depth), how come:

C:>ftype perl perl="C:\Perl\bin\perl.exe" "%1" %*

while regedit doesn't know that? Searching the registery, I find NOTHING for the exact string you posted (meaning, I assume, that I should perhaps set that?) but do find, searching for .pl:

HKEY_CLASSES_ROOT | | | | | .pl (Default) REG_SZ ntpfile | | Content Type REG_SZ NoteTab Pro document | | Perceived Type REG_SZ text | | | Perl (Default) REG_SZ ntpfile | | | | | ShellNew (Default) REG_SZ (value not set) | | PersistentHandler (Default) REG_SZ {5e941....}

... the last of which says, "ww go out and RTFM (some more)!"

Thank you.


Comment on Re^2: Win7, ASSOCiation , and @ARGV
Select or Download Code
Re^3: Win7, ASSOCiation , and @ARGV
by BrowserUk (Pope) on Mar 14, 2012 at 18:48 UTC

    What do you get when you run this command?

    >reg query HKLM\Software\Classes\Perl\Shell\Open\Command HKEY_LOCAL_MACHINE\Software\Classes\Perl\Shell\Open\Command (Default) REG_EXPAND_SZ "C:\Perl64\bin\perl.exe" "%1" %*

    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.

    The start of some sanity?

      C:\>reg query HKLM\Software\Classes\Perl\Shell\Open\Command HKEY_LOCAL_MACHINE\Software\Classes\Perl\Shell\Open\Command (Default) REG_SZ "C:\Perl\bin\perl.exe" "%1" %*
      REG_EXPAND_SZ? My iggerance is showing, again or is that peculiar to the 64 bit version? ww

        REG_EXPAND_SZ means that the value contains (or may contain) environment variables that are supposed to be expanded. Usually you have things like:

        %SYSTEMROOT%\System32\Drivers

        ... and have to hope that the application knows how to handle REG_EXPAND_SZ.

        Try running this. It just might fix your problem:

        >reg add HKLM\Software\Classes\Perl\Shell\Open\Command /t REG_EXPAND_S +Z /d "c:\perl64\bin\perl.exe \"%1\" %*"

        With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        "Science is about questioning the status quo. Questioning authority".
        In the absence of evidence, opinion is indistinguishable from prejudice.

        The start of some sanity?

        FWIW (and I'm even iggeranter than you in this respect): my (32-bit) win config, which seems to be identical to yours and runs an identical version of perl (see above), gives the same response as yours to the esoteric query suggested by BrowserUK:

        C:\>reg query HKLM\Software\Classes\Perl\Shell\Open\Command HKEY_LOCAL_MACHINE\Software\Classes\Perl\Shell\Open\Command (Default) REG_SZ "C:\Perl\bin\perl.exe" "%1" %*

        And yet, I get the expected output from your program.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://959627]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (11)
As of 2014-07-23 18:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (149 votes), past polls