G'day VinsWorldcom,
I got the same as you for 'assoc' and 'ftype' in cmd.exe:
C:\Users\ken\tmp>assoc | find /i "perl"
.pl=Perl_program_file
C:\Users\ken\tmp>ftype | find /i "Perl_program_file"
C:\Users\ken\tmp>
In the registry, I have exactly the same as you (except I have C:\Users\ken\local\opt\strawberry_perl\5_030_000\install instead of your C:\Strawberry).
In your PowerShell output, you show everything output to the PowerShell, instead of the commands starting with perl being output in a separate window. Did you do something else to achieve that?
In cmd.exe, I get much the same as you:
C:\Users\ken\tmp>perl .\test_platform.pl
Platform: MSWin32
Executable: C:\Users\ken\local\opt\strawberry_perl\5_030_000\install\p
+erl\bin\perl.exe
Enter to close window:
C:\Users\ken\tmp>.\test_platform.pl
Platform: MSWin32
Executable: C:\Users\ken\local\opt\strawberry_perl\5_030_000\install\p
+erl\bin\perl.exe
Enter to close window:
C:\Users\ken\tmp>perl test_platform.pl
Platform: MSWin32
Executable: C:\Users\ken\local\opt\strawberry_perl\5_030_000\install\p
+erl\bin\perl.exe
Enter to close window:
C:\Users\ken\tmp>test_platform.pl
Platform: MSWin32
Executable: C:\Users\ken\local\opt\strawberry_perl\5_030_000\install\p
+erl\bin\perl.exe
Enter to close window:
C:\Users\ken\tmp>
So, the answer to Question 1 seems to be to remove the
if ($^O eq 'MSWin32') {
print 'Enter to close window: ';
<>;
}
and run all scripts from "cmd.exe".
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
|
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
|
|