Forcing 'tell app' to use carbon, rather than classic app

Hi All,

I’m sure this is a lot easier to do than it seems.

Here’s what I’m trying to do.

I have a complex AS application I’m porting from OS 9 to OS X 10.2.3. In addition to giving it a nice Cocoa front-end, I’m now able to do a lot of what I was doing with Scripting Additions using the handy-dandy ‘do shell script’ command and the wealth of Unix tools at my disposal.

The problem I’m running into is this.

The machine where I’m developing - and ultimately running - this AS App has both Classic & OS X versions of some of the apps being driven via AppleScript. For instance, I’ve got both the classic & - I assume - carbonized versions of FileMaker Pro 5.5. I need to now have the ‘tell application’ directive link to the carbonized FMP, as opposed to the classic version, and I’m not sure how to direct the AS compiler in AS Studio/PB to do that.

I tried the naive trick of simply changing the old FMP’s name to ‘FileMaker Pro for Classic’. All that did was change the references in my AS code to ‘tell application “FileMaker Pro for Classic”’. When I tried to manually change these references to ‘tell application “FileMaker Pro”’, so as to force the AS compiler to bind to the proper version of the FMP, the AS compiler simply forced the references back to ‘tell application “FileMaker Pro for Classic”’.

I remember learning awhile ago how this binding is created, and I vaguely remember under OS 9 it was based on the app file’s type or creator. I assume it’s a bit different under OS X.

Can anyone offer a fix for this problem.

Thanks ahead of time for your help.

Cheers,
Bill Bug

Bill Bug
Senior Analyst/Ontological Engineer

Computer Vision Laboratory for Vertebrate Brain Mapping
Department of Neurobiology & Anatomy
Drexel University College of Medicine
2900 Queen Lane
Philadelphia, PA 19129
215 991 8430 (ph)

you can either create an alias to FileMaker Pro in ~/Library/Scripting Additions
or simply use
tell application “Filemaker Pro.app”

This might be what you are referring to:

tell application "Finder" to set fmp to application file id "FMP5" as alias