Detect PythonWin?

Peter Abel p-abel at t-online.de
Fri Aug 1 21:04:06 CEST 2003


mb at muenster.de (Martin Bless) wrote in message news:<3f29fe44.104328 at news.muenster.de>...
> IMHO PythonWin is great help in developing.
> 
> How can I do something like:
> 
> if detect("running on PythonWin"):
>     pass
>     # fake arguments ...
> else:
>     "proceed normal"
> 
> ?
> 
> Martin

Am I right that you would have the same problem when you
worked with the normal python shell or Idle or Boa or ...  ??
If true your problem would be solved by:

if len(sys.argv)>1:
  do_something_with(sys.argv[1:])
else:
  do_something_with(['fake','arguments'])

If not so ... sorry, I missunderstood you.

Regards Peter




More information about the Python-list mailing list