VISUAL QUICKPRO GUIDE FileMaker Pro 7 Advanced FOR WINDOWS AND MACINTOSH [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

VISUAL QUICKPRO GUIDE FileMaker Pro 7 Advanced FOR WINDOWS AND MACINTOSH [Electronic resources] - نسخه متنی

Cynthia L. Baron, Daniel Peck

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید











Using AppleScript with FileMaker Scripting


Although discussing AppleScript is outside the scope of a FileMaker Pro book, it's definitely worth a mention because it allows you to combine FileMaker scripting with almost limitless ability to affect Macintosh Finder functions (like automatically backing up FileMaker databases at specific times of the day), and to initiate actions in other AppleScript-aware programsfrom simply cutting and pasting text between applications to mining your Netscape cache for interesting GIF files.

This example uses a simple script that copies the contents of a FileMaker field, switches to Microsoft Word, and pastes the text into a document.

To send an Apple Event to another Mac application



1 .

Choose Scripts > ScriptMaker (Control+Shift+S/ Command+Shift+S).

2 .

In the Define Scripts dialog box, click New. When the Edit Script dialog box appears, name the new script (we use Paste into Word) (Figure 11.55).

Figure 11.55. This script name describes what its AppleScript does.


3 .In the Navigation section of the script step list on the left, double-click Go to Layout.

4 .From the Specify drop-down list in the Script Step Options section, choose the layout that holds the field data you want to copy. Our example uses the Contract layout (Figure 11.56).

Figure 11.56. For the Copy step to work properly, the field whose contents you want to copy must appear in the layout you specify.


5 .

In the step list on the left, scroll down to the Editing section and double-click Copy (Figure 11.57).

Figure 11.57. The Copy script step allows you to copy to the Clipboard all or part of the text contents of a field.


[View full size image]

6 .

In the Script Step Options section, click Go to Target Field to bring up the Specify Field dialog box. Double-click Contract to choose it from the field list. Leave "Select entire contents" checked unless you want to edit the field (Figure 11.58).

Figure 11.58. Leave "Select entire contents" checked to copy the entire contents of the field.


7 .In the script step list on the left, scroll down to Miscellaneous and double-click Perform AppleScript (Figure 11.59).

Figure 11.59. The Perform AppleScript step allows you to enter commands that are executed by AppleScript.


8 .

Under Script Step Options, click Specify.

9 .When the "Perform AppleScript" Options dialog box appears, type your AppleScript (Figure 11.60). Click OK three times to finish.

Figure 11.60. These AppleScript commands switch to Microsoft Word and paste data into its current document.



Tips

Although AppleScript is a very powerful tool for connecting FileMaker with other applications, it is not cross-platform. If you open a database file that uses AppleScript on a Windows computer, the scripts won't work.

To learn more about how to use FileMaker with AppleScript, check AppleScript for Applications: Visual QuickStart Guide by Ethan Wilde (Peachpit Press, 2001).


/ 227