Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

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

Recommended Posts

Posted

What I'm trying to do is provide a user with a help message for the field in which their cursor is located, the help message providing a tip about how to complete the field. I would rather not place the user in a scripted loop throughout the entire data entry process.

The first thought that comes to mind is a calculated field that relies on Get(ActiveFieldName) to select what help text to display.

Can anyone post an easy unscripted way to solve this particular problem? It is completely escaping me how to do it other than with the Get(ActiveFieldName) command, which shamefully does not work correctly (intuitively?) in anything other than a script. I know, I know, it's a feature, not a bug. Rrriiight.

Thanks.

Posted

I would use a Help button that incorporates Get(ActiveFieldName). I don't think there is a non-scripted way to do it.

It makes sense that Get(ActiveFieldName) won't work in most calculation fields, because calculations don't update until you leave a field, so this function would actually return the previous field's name. This feature is quite useful in some instances (just ask Ugo), but unfortunately not helpful for your situation.

Posted

Haynes,

Here's what I've done and I am moderately happy with the outcome.

First off I don't use the Get(ActiveFieldName) at all. I just put a 16px x 16px button next to the field(s) that has a question mark for its text. I have the button run a common script and pass a parameter of the tablename::fieldname for the field I want to describe. The script uses the Get FieldComment function to write the results to a global field. I then have a pop-up window show the global field. A button on the pop-up closes the pop-up window and returns the user to the original window.

This works fairly well because all I have to do to apply it to a new field is create the button with the tablename::fieldname parameter and add a comment to the field in the Define Database section.

I'd rather have a description show up when the user hovers over the field or label but that can't really be done with native FM.

Posted

Thanks for the replies. Both are very helpful.

I hear you Queue that Get(ActiveFieldName) does not currently work in MOST calculation fields. Will it work in any? If so, perhaps I can manipulate it to my suit my goal.

If not, I still tend to believe that that Get(ActiveFieldName) or a similar FileMaker-provided function SHOULD work in principal for what I'm trying to do, for at least 3 reasons.

First, FMP7 can detect that the cursor has entered a particular field, and certainly knows the identity of that field, since it can activate a pop-up list of data choices that it knows are assigned to that field. So why can't FMP7 provide the identity of that field to me?

Second, FileMaker makes Get(ActiveFieldName) visible and available in the Calculations dialog and does not limit its visibility and availability to ScriptMaker. Thus, Get(ActiveFieldName) should work in calculations. Don't tease me, FileMaker.

Third, FileMaker's help materials provide no indication that Get(ActiveFieldName) won't work in calculations, thus suggesting that it was intended to work in calculations and that its current non-functional status is actually a dysfunctional status, i.e., a BUG, which FileMaker should promptly exterminate

Off the soapbox. Other than using scripting, is there any way to use a pure calculation to solve my goal of providing a help message that is specific to the field the cursor is currently in? Is there any way to make Get(ActiveFieldName) work in ANY unscripted calculation? Thanks.

Posted

Upon re-reading your post, Queue, I see that you mentioned that Ugo has found a way to return the previously entered field via an unscripted calculation. I think I can work with that, considering that my user will likely visit the fields in a predetermined sequence. Can you post his method? Thanks.

Posted

It is definitely a mistake on FM's part not to have included a section warning against using certain Get functions in calculation fields. It was also a problem in previous versions when Get functions were Status functions. I guess they figure you'll find out one way or the other eventually, which is not the best way to handle it...

Anyway, you'll need a text calculation with an auto-enter calculation (and 'Do not replace existing value for field' deselected) of either

Case( field1 & field2 & field3 & ... & fieldN; Get(ActiveFieldName); Get(ActiveFieldName) )

or

Evaluate( "Get(ActiveFieldName)"; [field1; field2; field3; ... ; fieldN] )

where field1 to fieldN are all the fields to be tracked.

Again, the calculations will not update until you modify a field and exit the record or tab to another field. But at least you can now determine the last modified one.

Posted

Thanks so much Queue. Both approaches work.

I have implement them as:

Case (Evaluate( "Get(ActiveFieldName)"; [field1; field2; field3;...;fieldN] ) = "field2"; "The current field is field1"; Evaluate( "Get(ActiveFieldName)"; [field1; field2; field3;...;fieldN] ) = "field3"; "The current field is field2"; [etc.];"")

where the phrase "The current field is field1" can instead be the help message for the appropriate field, or whatever other text is desired.

If I set the tab order for the layout, and insert an otherwise unnecessary field1, this approach, although awkward, just might fulfill the objective, provided (as you helpfully warned) that data is entered or edited in the previous field. If data is not entered, the calculation is not evaluated and no help message appears.

In any event, I will try this approach as well as the suggested Help button approaches to see which is ultimately more practical for my users. Thanks again.

Posted

Ted, I agree--there should be a "tool tip" when one hovers the mouse over a field label, providing help to the user for that field. This feature is available in MATLAB GUI.

Posted

Well, if Get(ActiveFieldName) returns field2, then the currently active field (if the cursor is in any field) is field3, assuming the tab order goes from field2 to field3. So this seems a bit backwards.

In any case, you can use something like

Evaluate(

"Let( T = "field1

This topic is 7323 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.