Python Forum
working directory if using windows path-variable
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
working directory if using windows path-variable
#3
Oh dear...

Yes, you are right. It's working this way.
I added

os.chdir(os.path.join(os.path.dirname(os.path.abspath(__file__)), './'))

so that it works out of visual studio code... Doh

Thank you!!!
Reply


Messages In This Thread
RE: working directory if using windows path-variable - by chitarup - Nov-28-2023, 11:36 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  create a default path with idle to a specific directory greybill 0 893 Apr-23-2023, 04:32 AM
Last Post: greybill
  [SOLVED] [Windows] Right way to prompt for directory? Winfried 4 2,100 Jan-17-2023, 09:28 PM
Last Post: markoberk
  Pynput Library not Working with Windows jacknewport 1 2,398 Mar-26-2022, 07:09 PM
Last Post: snippsat
  WebDriverException: Message: 'PATH TO CHROME DRIVER' executable needs to be in PATH Led_Zeppelin 1 2,241 Sep-09-2021, 01:25 PM
Last Post: Yoriz
  [solved] subdictionaries path as variable paul18fr 4 2,692 May-18-2021, 08:12 AM
Last Post: DeaD_EyE
  Subprocess.Popen() not working when reading file path from csv file herwin 13 15,285 May-07-2021, 03:26 PM
Last Post: herwin
  In put path and directory Led_Zeppelin 1 2,495 Apr-23-2021, 03:25 AM
Last Post: Larz60+
  Spyder stopped working in Windows 10 gammaray 3 3,103 Apr-19-2021, 05:33 PM
Last Post: jefsummers
  Setup working directory in IDLE Pavel_47 3 3,839 Mar-06-2021, 08:59 AM
Last Post: Pavel_47
  Does anyone have unicurses panel functions working on a Windows 10 platform? pjfarley3 0 1,489 Oct-11-2020, 04:41 AM
Last Post: pjfarley3

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020