Sintax Posted March 26, 2004 Posted March 26, 2004 I noticed in Script Maker just now that I can make my own dialog boxes. There are not a whole lot of options but if I could do this it would save me a lot of work! I know I can make a dialog box and have up to three buttons on it. What I don't know is if I can make each button go to a different Layout. If I could... oh, would that be awesome! Version: v7.x Platform: Mac OS X Panther
CyborgSam Posted March 26, 2004 Posted March 26, 2004 Sure, just like in FM6. After the Show dialog script step, check for which button using If tests & Get ( LastMessageChoice ) = 1 or 2 or 3, and have each If test do a Go to Layout. Is this what you were asking?
Sintax Posted March 26, 2004 Author Posted March 26, 2004 Yes, but I am new to filemaker so I never used 6. So I will need the Show Dialog Box script and then another script for each layout? Could you give me a more detailed example of the code for the script?
Aussie John Posted March 26, 2004 Posted March 26, 2004 Sintax something like that should work (i'm sure someone will have a more elegant way to go it) if Get ( LastMessageChoice ) = 1 go to Layout <layoutname> endif if Get ( LastMessageChoice ) = 2 go to Layout <layoutname> else go to Layout <layoutname> endif by using the input fields section the user can input data directly into fields
Sintax Posted March 26, 2004 Author Posted March 26, 2004 Thanks Aussie John - Does that go into the Specify Calculations spot of the Dialog Setup or is this a seperate script all together?
CyborgSam Posted March 26, 2004 Posted March 26, 2004 This is all one script, I'll put each Script step on a separate line: Show Custom Dialog[... If [Get( LastMessageChoice ) = 1] Go to Layout [foo] Else If [Get( LastMessageChoice ) = 2] Go to Layout [zoo] Else If [Get( LastMessageChoice ) = 3] Go to Layout [poo] End If In the first If test, Specify Calculations gets the: Get( LastMessageChoice ) = 1 In the Show Custom Dialog, the Specify buttons are for using a field's text for the dialog rather than typing in your own. Type in your own until you're used to how this works. Clearer?
Jim McKee Posted March 26, 2004 Posted March 26, 2004 The logic to handle the contingencies of which button was clicked goes directly after the "Show Custom Dialog" step in your script (as in Sam's example). Version: v7.x Platform: Mac OS X Panther
Sintax Posted March 26, 2004 Author Posted March 26, 2004 Awesome you guys! Once again you have come through (in record time!) and helped me out. I used to think the MovableType forum was the best around... now I am thinking otherwise.
Aussie John Posted March 27, 2004 Posted March 27, 2004 Sintax said: Thanks Aussie John - Does that go into the Specify Calculations spot of the Dialog Setup or is this a seperate script all together? This is a separate script ie put your "show custom dialog" before the items i indicated Version: v6.x Platform: Mac OS X Panther
Recommended Posts
This topic is 7550 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now