Get (ActiveLayoutObjectName)Posted by: MaxR / Wednesday, May 16, 2007 – 6:19pm
Using Object Info I assigned a name to a graphic button but Get(ActiveLayoutObjectName) wasn't getting it. FMPV8.5 Online Help under Get (ActiveLayoutObjectName) says: "Example Further, under Notes "Naming Objects", the rules state: "You can assign a name to an individual object or to a grouped object, but not to multiple objects. " There is a difference between the mouse pointer and the cursor. The cursor is where the text insertion cursor is located; the object that has the "focus". So for instance if the insertion point was in field "first name" then this is the *active* layout object. A button can only become an active object if it is in the tab order and you have tabbed to it; or if a script action "go to object" has taken place. Here is a solution: Create two dummy fields: One, and Two (they could be globals, so you can use them anywhere) and use field One as the button, and assign whatever name you want. Make the field a button and script as follows: Go to Field [One] Field two is not on the layout so the effect of the third step is to exit the One field. Now $$Object contains the object name and the script can continue. You can place a passive text block on top to name the "button." ------ Filed under: Scripting
|
Be Notified!Let us tell you when a new video is posted. We'll send you an email with a direct link right to your email inbox.
Make sure and whitelist (or add to your address book editor@filemakermagazine.comFileMaker Reference Tool
* $29.99 is the FMPug member price for a printed copy. 10 Most Recent Videos
|