Jump to content

Stop value lists from automatically unfurling?


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

Recommended Posts

This is a real annoyance and one I haven't addressed before though I've wanted to. Am at that stage where I can start cleaning up annoyances.

In main db layout, 4 fields can be tabbed to. Second to last one is field that requires somewhat frequent editing. After hitting enter to take in data from its value list, it naturally and properly tabs to next and last field in tabbed sequence. However, what is _not_ nice is how this last field automatically shows the value list; it unfurls downward. This is no good. Any way to stop that from happening? Once input, that last field rarely needs to be entered and, unfortunately, all the navigations buttons get obscured by the menu revealed. Also, requires mouse click to get menu back where it should be. Very fiddly and ... _annoying_!

Pls help. Getting close to a good working db, it's just things like this that are making life difficult since it's so frequent. ooo.gif

Link to comment
Share on other sites

One option is to duplicate the field, then remove it from the Tab order. Format its twin as a Standard field and verify its order in the Tab order. Then put it underneath the original. Now the menu will only pop up when the field is actually clicked.

Link to comment
Share on other sites

Hi Diana,

A neat addition to Queue's suggestion would be the inclusion of a small button (eg with a downward arrow) at the right of the stacked field, attached to a script along the lines of:

Exit Record/Request

Go to Field [Last Pop-up}

Go to Next Field

That way if someone has already tabbed into the field but wants to activate the pop-up list, they'll be able to do so efficiently by clicking on the arrow/button.

Otherwise, in order to access the pop-up after tabbing to the field they would have to click out of the record or tab to another field before being able to activate the pop-up by clicking on the field - which I suspect users would be apt to regard as counter-intuitive. wink.gif

Link to comment
Share on other sites

Excellent, thank you!

I went ahead and started work on this. I've got the two field boxes now, but I've run into a snag in that I don't know where to go from here.

I created a duplicate field. I lengthened the original slightly and removed border and made the original field same colour as background so any "visible" part on the right fades into the background. I thought of the pulldown arrow myself which is why I left the extra space on the right for it (however, with script, extra space may not be necessary (?) I'll just put the arrow beside the original field?).

Thing is that I thought about the trouble of having two identical fields. Thought there would be trouble with that so I created a new one called "EmptyCategoryField" (vs. the original "Category" name) "associated" the duplicate field to this new name. Also, thought it would be best to allow no user input into that field. Don't know if I've done something good with that, but it's what made sense to this newbie.

Thing is that unless there's a way to make a fill colour transparent, the instant I did the above, the fill colour became opaque and obscured the data. Now data only shows when field is clicked into, which is no good.

What to do to fix this, pls? Or did I not deal with this duplicate field correctly?

Perhaps what would be better is if there is tutorial somewhere to document this procedure fully?

****************************

Exit Record/Request

Go to Field [Last Pop-up}

Go to Next Field

Question - there are two typs of brackets in 2nd line: [ and }, is this correct?

Question - I no longer have the original field in the tab sequence. Will "Go to Next Field" command still work?

Thank you everyone for your help! I definitely could not have gotten even halfway to where I am now without everyone's help. crazy.gif

Link to comment
Share on other sites

Hi Diana,

First things first, humble apologies for the two different types of brackets - that was a typo. blush.gif

As regards two copies of the same field on the layout, I can see why you felt intuitively that that might be a problem. But you can take it from both Queue and I that it won't. It may constitute 'bending the rules' a little, but I assure you that they won't break, and that this is a technique long used by developers the world over. wink.gif

Meanwhile although it is indeed possible to apply a transparent fill attribute to a field, it should not be necessary in this instance. FileMaker automatically brings the active field to the front of the stacking order, while the cursor is in it, so users will see the back field when they tab to it, even though the front field is opaque.

Finally, as regards the button, I omitted to mention that in order to use a script to access the frontmost field in the way I indicated, the field *will* have to be in the tab order, but should instead have the 'Allow entry into field' option turned off in the 'Field Format...' dialog. The frontmost field itself should then also be defined as a button and attached to the same script as the button beside it. That way, clicking on either the field or the button will activate the pop-up list, but the pop-up will not appear when users tab to the field.

So that you can see the effect 'in motion', I've put together a lightning-fast demo that shows the whole technique - stacked fields, button and script - working. It is attached to this post (see attachment link in the header bar of the post).

List.zip

Link to comment
Share on other sites

Yes, I see exactly what you mean now. I didn't understand perfectly before. I've dealt with software that doing that type of thing would have resulted in conflicting codes and errors would result. This is an entirely different situation, I feel I understand why. Even if one could enter data via both fields, though it's not set up that way now, since data is displayed in effect there is a tendency only to enter the data once anyway. It won't "write" the data twice as we're entering into the one field effectively. It took the afternoon for this to bubble around in my brain but I've caught on. Hard when first dealing with issues like this as it's so abstract.

Thanks re the brackets, I thought so but just wanted to make sure.

Thank you so very much for your comprehensive response. Much appreciated!

I've reversed changes made to duplicate field. Looks very good so far. Now in process of adding pulldown button for access to original field. Thanks. Will report back.

Link to comment
Share on other sites

  • 10 months later...

This is a great tip... thanks everybody!

But I can't get it to work properly in a portal. It works fine on the first record in the portal, if I try to display the value list for the second record the script takes me back to the first record (and displays the value list). What have I done wrong?

Thanks

Dave

Link to comment
Share on other sites

Hi,

With a portal, you would just call a GoToField [ ] making sure you're referencing the Portal's relationship.

An Exit Record, on the contrary would exit you from the portal row.

If you need to exit the record, nevertheless, for some redraw problems, then store the portal row in a global.

SetField[gRow, Status(CurrentPortalRow)]

ExitRecord/Request

GoToPortalRow[byfield-gRow]

GoToField[yourportalrelationship::yourfield]

HTH

Link to comment
Share on other sites

...nevertheless, for some redraw problems...

You can avoid any redraw (portal pop) problems, provided your portal has at least one other field in it, by using the alternate script:

Go to Field [PortalRelationship::OtherField]

Go to Field [PortalRelationship::PopUpField]

Go to Next Field

This approach ensures placement of the focus on the correct field, without leaving the portal row (which otherwise is lost when the record is exited). Voila - no portal refresh! cool.gif

Link to comment
Share on other sites

Dave,

It works here (the original method, the method Ugo described or the variant I posted a short while ago) with value lists defined in another file (including custom value lists and those which take values from a field).

I note that Ugo's script may need an additional 'Go to Next Field' step on the end, if you are dealing with stacked fields as described earlier in this thread.

Link to comment
Share on other sites

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