I’m runnung xojo on Macos 14 Mojave. My app has an array of around 100 pdf files, names of which are also set out in a Listbox The files are all stored in the same location.
When the user selects a pdf from the Listbox, the file should open, and in most cases it does, using the default app Preview (I’ve also set Adobe Reader as the default and exactly the same problem described below happens).
Nearly always everything works fine, but there are some pdfs that will not open, and I get the error message “The application “[Filename].pdf” could not be launched because a miscellaneous error occurred (OSStatus -36).”
To make sire there is nothing in my application that is causing the error, I have created a new desktop project with a button on the screen. The Action code for this button is
Dim f as FolderItem = GetOpenFolderItem("???")
I have created a test folder with 20 of the pdfs and 3 of these will not open. It’s always the same 3!
I’ve seen a thread on this forum on a similar problem but there did not seem to be any solution.
Has anyone any ideas what might be causing this? And what can I do?
Most of the pdfs were downloaded from the internet, but I have created a few of them myself using various apps.
Is the format of a pdf file sometimes different?
All the pdfs open ok when this is done from Finder, or from within Preview, or within the Chrome browser
Incidentally, they also all open ok when I use an Applescript app I wrote to do the same thing as my Xojo app,
Any solutions or suggestions gratefully received!