Quantcast
Channel: Xojo Programming Forum - Latest topics
Viewing all articles
Browse latest Browse all 3827

AppleScript prompted by Xojo App fails

$
0
0

Running current version of Xojo/MacOS/AppleScript

I have an app written in Xojo that instructs Keyboard Maestro to run various macros that have been written in that application. Xojo accomplishes this feat by running an imbedded AppleScript.

The AppleScript itself is very straight-forward. You are asking Keyboard Maestro (which is a commercial application) to run a specific macro that it knows about and you pass it a single parameter to give that macro some particular bit of information. The AppleScript looks like this:

For some time, this worked just fine. It has been working on my own machine for a long time (years).

Then a user told me that when he tried it nothing happened. As best I can tell, this is related to permissions under Privacy & Security in System Settings. When I installed everything de novo on a new machine, I ran into the same problem.

When I ran the AppleScript on the new machine using Terminal it worked. The first thing that it did was ask for permission.

I gave it permission and it worked correctly.

However, when I had my Xojo app run this same AppleScript nothing happened. It did not ask for permission and the AppleScript, I assume, did not run.

On my personal machine, looking at System Settings :: Privacy & Security :: Automation

The Xojo app is ASK_Palette and there it is under Automation. If you look for details, it shows you

None of this is seen on the new machine.

With this sleuthing, I believe the problem is that the Xojo app does not ask for and therefore does not get permission to cover the use of the AppleScript. All I can say is that this must have worked sometime in the past. The app continues to work fine on my own machine.

Does someone understand what this issue is and how to solve it?

3 posts - 3 participants

Read full topic


Viewing all articles
Browse latest Browse all 3827

Trending Articles