Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 7722 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

i have been trying to do this for a while with no success.

I need to do some kind of keyboard in filemaker, i have 30 fields, each one with a code in it. i need a script that allow me to read the contents of any field and put it in a temp field, the challenge in this, is that each field is a button and have to work with the same script.

The escript have to do something like this:

set field("temp","Status(CurrentFieldContents)")

the problem is that i have no chance to select the field because is a button.

someone tell me that the only way to do this is making a script for each button, but, if i need to do a keyboard with a 100 buttons?.

there is a way to do this with only one script?.

Posted

FileMaker 6 cannot pass a parameter from a button to a script. And as you've found, Status(CurrentField) won't help you here. So, make 100 scripts.

Posted

Edited :OOpps, didn't read the post correctly, so this won't probably solve your problem.

At least, it may help in having a script rather than 30 if you can plcae the fields next to the button in a vertical way. Too many ifs....

If you can have yur buttons staying all together and if you currently run at least FM5.5, then you can do this by creating another file.

Store any button definition there as a separate record with 'ButtonName' and 'TargetField'

Use a constant relationship from the Main to the Buttons.fp5 file involving an auto-entered num (result1) on both sides.

Then draw a portal and place the 'ButtonName' field in the first row, draw a button there if you wish.

The script now would look like :

SetField[g_FieldName, ::Constant:TargetFieldName]

Then use a GetField() to get the content of your field.

SetField[g_temp,GetField(g_FieldName)]

HTH

  • Newbies
Posted

Thx Ugo, but if i have a portal instead of fields as buttons i can't display them in the screen like is required, thx any way.

Posted

I wonder if you could do this with 24U simple help. It knows where the cursor is, and puts up a message. Can the script capture the content of the message?

Posted

Hm, yes, it can be done with 24U Simple Help, the command is External("24uH-Control", "list-tags|last"). This gives the coordinates and text of the last tag, which would be the tag under your mouse.

This topic is 7722 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.