<

Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x

How do I make .pl run as perl programs on windows

Published on
8,058 Points
4,858 Views
2 Endorsements
Last Modified:
On Microsoft Windows, if  when you click or type the name of a .pl file, you get an error "is not recognized as an internal or external command, operable program or batch file", then this means you do not have the .pl file extension associated with the perl interpreter.  This is normally done by the installer, but not always.

To associate files:
    1) Start Windows explorer
    2) Select, from the menu, Tools -> Folder Options
    3) Select the File Types tab
    4)  Look in the list for a PL extension.  If it does NOT exist:
        4a) Click New
        4b) Type pl for extension
    5) Select the PL extension in the list
    6) In the section "opens with", click Change
    7) Select perl.exe
    8) Click OK until all Windows are closed.
2
Comment
Author:Adam314
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 39

Author Comment

by:Adam314
I've seen this issue several time in the perl programming zone.  The problem is that, on windows, the file extension is used to determine how a file should be handled.  If, when installing perl, the .pl file extension is not associated with the perl interpreter, then, when the user tries to run the perl program by double-clicking the file, or typing the name, they get an error.

The solution is very simple - associate the .pl file extension with the perl interpreter.  This is the reason for so few words.

Perhaps this isn't worthy of an article.  I decided to write it because I've seen the problem several times, and thought it would be helpful.  
0
 
LVL 40

Expert Comment

by:mrjoltcola
Changing status to notify. Apologies, the articles system is still sort of a "beta" status. Please see my 2 comments above.
0
 
LVL 39

Author Comment

by:Adam314
I'll update the instructions to work with Vista also.  I only have XP to test, but from your notes, it seems that the right-click method works on both XP and vista, so I'll provide instructions for that method.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Join & Write a Comment

Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans

Keep in touch with Experts Exchange

Tech news and trends delivered to your inbox every month