Skip to content

Windows: Opening .gan files via file association or command line fails unless working directory is the installation directory #2805

@LifeIsBits

Description

@LifeIsBits

Title

Windows: Opening .gan files via file association or command line fails unless working directory is the installation directory

Description

Environment

  • GanttProject: 3.3.3316
  • Operating System: Windows Server 2025
  • Environment: Remote Desktop Session Host (RDSH)

Problem

Opening a .gan file by double-clicking it in Windows Explorer does not open the project.

The same happens when launching GanttProject from the command line and passing a .gan file as an argument.

GanttProject starts (a process is visible in Task Manager), but the project itself is not opened and no error message is displayed.

Opening the exact same project through File → Open from within GanttProject works correctly.

Steps to Reproduce

  1. Install GanttProject 3.3.3316.
  2. Create or obtain a valid .gan project file.
  3. Close all running GanttProject processes.
  4. Double-click the .gan file.

Expected Behaviour

The project should open automatically.

Actual Behaviour

  • GanttProject starts.
  • The project is not opened.
  • No error message is displayed.

Additional Findings

The issue can also be reproduced from the command line.

Does not work:

"C:\Program Files\GanttProject-3.3\GanttProject-3.3.exe" "C:\Temp\Test.gan"

Works:

cd /d "C:\Program Files\GanttProject-3.3"
GanttProject-3.3.exe "C:\Temp\Test.gan"

Opening the project through File → Open from within GanttProject also works.

Additional Observation

When opening a .gan file directly (double-click or command line), an app\plugins folder is automatically created next to the project file.

Example:

Image

This folder is not created when opening the same project through File → Open inside GanttProject.

This behaviour may indicate that the application is using a different working directory when launched with a project file argument.

Workaround

A workaround was implemented by launching GanttProject through a VBScript wrapper which first sets the working directory to the installation directory. After doing so, opening .gan files works correctly.

Notes

The issue was reproduced multiple times and is not related to:

  • File association configuration
  • Corrupt project files
  • UNC paths
  • User permissions

The same .gan file opens correctly through File → Open once GanttProject is already running.

Metadata

Metadata

Assignees

No one assigned

    Type

    No fields configured for Bug.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions