Issue with getting the opened project's name
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2018-03-28
09:39 AM
- last edited on
2022-12-06
01:43 PM
by
Daniel Kassai
2018-03-28
09:39 AM
Hello,
I'm trying to get the current opened project's name. Here is my code, which should work according to the documentation, but it doesn't seem to work:
P.S. I am opening an already saved project.
Any help will be appreciated,
Julian
I'm trying to get the current opened project's name. Here is my code, which should work according to the documentation, but it doesn't seem to work:
GSErrCode err; API_ProjectInfo info; err = ACAPI_Environment (APIEnv_ProjectID, &info, nullptr); if (err != NoError){ ErrorBeep ("APIEnv_ProjectID", err); } else{ WriteReport("project path is %s", info.projectPath); // returns null always WriteReport("project name is %s", info.projectName); // returns null always }Is there any other specific thing that should be done in order to make this work? Is the project name something different than the filename of the pln?
P.S. I am opening an already saved project.
Any help will be appreciated,
Julian
Labels:
- Labels:
-
Add-On (C++)
2 REPLIES 2
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2018-03-28 10:57 AM
2018-03-28
10:57 AM
I have tried printing the untitled property:
WriteReport("project untitled is %s",(info.untitled)?"true":"false"); // returns false alwaysWhy it says that the file is not saved? I'm opening an already saved project.

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2018-04-06 01:19 PM
2018-04-06
01:19 PM
Hello,
Unfortunately this is a bug. We will try to do the best to fix it as soon as possible.
Best,
Mihály
Unfortunately this is a bug. We will try to do the best to fix it as soon as possible.
Best,
Mihály