A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-list/2005-September/310679.html below:

command line path

command line pathmclaugb mclaugb at nospam.gmail.com
Mon Sep 5 11:16:57 EDT 2005
I am trying to pass the name of several files to a python script as command 
line arguments.  When i type in


python ImportFiles_test.py C:\Program Files\National Instruments\LabVIEW 
7.1\project\calibration\FREQUENCY_
13.CSV

The following error results:

C:\Program Traceback (most recent call last):
  File "C:\Documents and Settings\bm304.BRYANPC\My 
Documents\Python\ImportFiles_test.py", line 10, in ?
    input = open(file1, 'rb');
IOError: [Errno 2] No such file or directory: 'C:\\Program'

I debugged a little and what is happening is the space in "c:\Program Files" 
and "...\National Instruments..\" is being parsed as separate arguments and 
i only wish for them to be parsed as one.

How do I get pass a path string containing spaces?

Regards,
Bryan 



More information about the Python-list mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4