By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,421 Members | 1,271 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,421 IT Pros & Developers. It's quick & easy.

How to import filenames with special characters?

P: n/a
How would I import a python file whose name contains characters like .'s or
!'s?

Is there really _no_ way to do that? I have to use plain jane letters and
numbers for everything?
Jun 27 '08 #1
Share this Question
Share on Google+
1 Reply

P: n/a
inhahe wrote:
How would I import a python file whose name contains characters like .'s or
!'s?

Is there really _no_ way to do that? I have to use plain jane letters and
numbers for everything?
The import statement can't help you, but take a look at the __import__
builtin function and the standard module named "imp".

Gary Herron
*
*
>
--
http://mail.python.org/mailman/listinfo/python-list
Jun 27 '08 #2

This discussion thread is closed

Replies have been disabled for this discussion.