June 13, 200520 yr How can I access a cell in a portal row? This did not work: tell application "FileMaker" set myURL to cell "URL" of current record end tell and this neither: tell application "FileMaker" set myURL to cell "URL" of table "Exemplare" of current record end tell where table "Exemplare" is the portal table. Thanks for your help.
June 13, 200520 yr You write it much the same as it is written in FileMaker, with the table occurrence name followed by "::". To get a field's value from the 1st row: set theCell to cell "Children_ParentIDs::FirstName" of current record But I don't see any easy way to get something from one of the other rows; other than doing a find or show using the parent ID in the other table, then going to the 2nd record (much like you'd do in a FileMaker script). There is no "portal" object in FileMaker's AppleScript dictionary.
June 13, 200520 yr Author Thanks Fenton. That's what I have assumed. What I do now: First a Goto Related Record script step to another layout, then use the code as in the first example, then go back to the original layout.
June 13, 200520 yr Are you just trying to get data from the 1st row? If so, then you can do it from the parent record, using the TO::field syntax.
June 13, 200520 yr Author No, this can be from any row. It's a little button left to the URL that opens the URL in a browser (as you might know, the Open URL script step does not work correctly, that's why I have made a workaround with AppleScript). We have about 2400 URLs in this table (and about 600'000 in two other tables). You see the problem with the Open URL bug.
June 13, 200520 yr How about set the related URL field into a global field, then open the global URL. I use the following syntax; FileMaker 7 is not happen with "open location" directly. tell application "loginwindow" to open location theURL
June 13, 200520 yr Author Sorry, forgot to say that the solution with GTRR works fine. Thanks for your help, Fenton.
June 17, 200520 yr I have a similar problem but in reverse order using FM 5.5 I am using a apple script with-in FM to send mail. I have a main database called "Test" with a related file called "emails". There is a portal in Test that shows all related records in the emails database. I created a button on Test to generate an email from FM inserting fields from the portal. I can get the funtion to work when I just run it straight in the emails database, did this to test the function, then changed the field names to emails::FieldName for each field I wanted to add to the email. But I get and "Object not found" error when running it from Test. Any suggestions? Here is the code. set theAddress to cell "emails::SendTo" from current record
Create an account or sign in to comment