T
TechieInsights
__file__ command does not work when compiled to exe. It makes since
because the file is now in a compressed library. Is there a
replacement or something else you can do? The real problem is that
when you create an exe of your program with python embedded, you can't
always guarantee that your current directory is the directory of your
program. I guess when you could just set a registry entry on
windows... but it would be nice to have a quick fix for this (like
os.path.dirname(__file__)).
Thanks,
Greg
because the file is now in a compressed library. Is there a
replacement or something else you can do? The real problem is that
when you create an exe of your program with python embedded, you can't
always guarantee that your current directory is the directory of your
program. I guess when you could just set a registry entry on
windows... but it would be nice to have a quick fix for this (like
os.path.dirname(__file__)).
Thanks,
Greg