Menu

Page cannot find my image files and I can no longer open my project

Anonymous
2021-08-05
2021-08-13
  • Anonymous

    Anonymous - 2021-08-05

    Good Day,
    I created a Python GUI with PAGE but when I closed it and tried to reopen it I get this error saying my image cannot be found in my project folder. However all the images are there. Please find attached screenshots of the issue.

     
  • Greg Walters

    Greg Walters - 2021-08-05

    Good morning.
    PAGE on Windows has a VERY serious issues when using images. They MUST be in the same folder as the code or at least a sub folder of that folder.

    According to your error1.png, PAGE is trying to tell you that it can't find the images which are located as the following...

    az_jpg "../Users/FUNMISE ADEFILA/Pictures/az.JPG" \
    azlogo_jpg "../Users/FUNMISE ADEFILA/Pictures/azlogo.JPG" \
    
    Your error2.jpg shows the path as "Desktop/Group_A_project".
    

    The error1.jpg shows the images are located at "C:/Users/ariel/OneDrive/Desktop/Group_A_project" .

    Your development folder should look something like this...

    DevelopmentFolder
    | Group_A_project
    | codefile.tcl
    | codefile.py
    | codefile_support.py
    | images
    | az.jpg
    | azlogo.jpg
    ....

    In addition, under "normal" circumstances, jpg files are not supported by PAGE / Tkinter without support from the PIL library. Having the images in .png or .gif format works much better for those specified during design time. Using the PIL library, you can easily embed the files in the support module.

    I hope this helps,

    Greg

     
    • Anonymous

      Anonymous - 2021-08-05

      The images are in the same folder as the tcl file but I still get the same error. I also changed the paths:
      set image_list { \
      az_jpg "C:/Users/ariel/OneDrive/Desktop/Group_A_project/az.JPG" \
      azlogo_jpg "C:/Users/ariel/OneDrive/Desktop/Group_A_project/azlogo.JPG" \
      }

       
  • Greg Walters

    Greg Walters - 2021-08-05

    Do the files actually end in "JPG" or "jpg"?

    Again, I suggest you convert the images to PNG format and try linking those into the code.

     
    • Anonymous

      Anonymous - 2021-08-05

      I converted the images to PNG format and updated the paths. But I still have the same issue
      set image_list { \
      az_jpg "C:/Users/ariel/OneDrive/Desktop/Group_A_project/az.PNG" \
      azlogo_jpg "C:/Users/ariel/OneDrive/Desktop/Group_A_project/azlogo.PNG" \
      }

       
  • Greg Walters

    Greg Walters - 2021-08-05

    The only other thing that I can think of is the possibility that PAGE might be having an issue with the OneDrive pathing.

    I will try to discuss this with Don today. In the mean time, you might try working the project from a local drive, not a OneDrive path.

    I will update here as soon as I get Don's input.

     
    • Anonymous

      Anonymous - 2021-08-05

      Thank you

       
  • Greg Walters

    Greg Walters - 2021-08-06

    Sorry for the delay in getting more information to you. I ended up being sick after speaking to Don. I should have known something was up when I wasn't able to come up with an answer.

    PAGE projects should always be run from the development folder. This is true for all os versions of PAGE but especially true for Windows and for any projects involving graphic images.

    DO NOT use the desktop shortcut to start PAGE. Instead, either use the command prompt (DOS Box) to navigate to the development folder or use the File Explorer to navigate there then use <ctrl> L to activate the address bar box then type "cmd". This will open a new command prompt window. From there, assuming your system has PAGE in the path statement, type "python3 c:\page\page.py" or possibly just "page.bat"</ctrl>

    This information can be found in the PAGE documentation under Installation on Windows.

    Greg

     
    • Anonymous

      Anonymous - 2021-08-13

      Okay. Thank you

       

Anonymous
Anonymous

Add attachments
Cancel





Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.