Jump to content
Salesforce and other SMB Solutions are coming soon. ×

Commit and Popup Lists


MrEase

Recommended Posts

In a presentation with contacts I want to show the country of the company this contact is from.

To change the country I created a popup list with company::IDcountry.

As I change IDcountry, the field showing the related country field doesn't change until I commit the field (clicking anywhere).

Is there any way to commit the record when you leave the popup list without having to press any additional button.

Link to comment
Share on other sites

you can format the popup as a button that calls a commit script.

 

Code:


set field[gTemp, "PopupField"]

set field[gCounter,"0"]

go to field [select, "PopupField"]

loop

pause/resume script ["00:00:01"]

exit loop if ["(PopupField =/= gTemp and not IsEmpty(PopupField)) or gCounter>10"]

set field [gCounter, gCounter+1]

End loop

commit record/request


 

the script waits for a field value change in the loop, but times out also in case the user does not change the popup field value. it's not especially elegant but it works.

 

kjoe

smile.gif

Link to comment
Share on other sites

thanks, this works but the screen flickers with every loop, visualy not elegant at all.

A pitty FM can't track mouse activity or poplist exits...

Link to comment
Share on other sites

I have no trouble with the flickering screen on mac 10.3.x. All I'm seeing is a slightly nervous mouse pointer. Do you use windows? I remember a thread about this only a search with all the obvious keywords yielded no results.

Perhaps inserting a Freeze Window after the Go to field and before the loop start may help.

 

kjoe

smirk.gif

Link to comment
Share on other sites

If it's on Windows, you can shorten the script, but you have to use a menu and not a list.

 

Commit Records/Requests

Go to Field [PopupField]

Pause/Resume Script [1]

Commit Records/Requests

 

The menu will stay open until a selection is made or the user clicks outside of the field.

Link to comment
Share on other sites

I am using WinXP, -Queue-'s solution is nice but since the list of values is very long I would prefer something smaller...perhaps I'll have to create a new presentation with a portal of the values.

Link to comment
Share on other sites

  • 2 years later...

On the subject of flickering FileMaker screens while using Windows, I found a fix of sorts: if you're using a Microsoft brand* wireless mouse there's an applet that runs in the background called ipoint.exe. If you use the "three-fingered salute" to bring up the Windows Task Manager windoid, click on the Processes tab, find ipoint.exe, then "end" it--problem solved. The only drawback with ending the process is that some of your mouse's programmable features may be disabled, but it's a small price for screen sanity.

 

 

I do have a question, Queue: say you have _a lot_ of pop-up menus; what's the most elegant way to codify your script above so all it would need is a variable instead of having to make many, multiple copies of your script?

 

 

 

 

*I don't know about other wireless mouse brands causing the same problem; I guess it depends on their drivers.

Link to comment
Share on other sites

Hi, I'm grappling with the annoyance of long country lists, too.

 

Here are my thoughts: if I have a table of countries I don't really want to have to scroll through Afghanistan and Antigua before I get to the countries I really deal with regularly. Some websites just manually add their "VIP" countries at the top, and that might be the way to go, but I like the idea of encoding concepts rather than data.

 

One idea would be to set up weighting fields with checkboxes that each give a value of 1, e.g. "EU member state", "Council of Europe member state", "European Economic Area member state", etc. Then have a field that adds up these values and sort by the calc field.

(Wait - it just occurred to me I could do that with a single field formatted as a checkbox set based on the value list and a calc field that gets the value count. Correct?)

 

OTOH, it would probably make more sense to just list, say, the ten countries we deal with most often ahead of all the rest, with our own country listed first. I'm thinking of something along the lines of adding 1 to a number field every time the country is selected somewhere and having a field that assigns 0 to our own country, 1 to the top ten countries, and 2 to all other countries, so that the sorting could be based on this field first followed by the country name field.

 

Or is this really overkill?

 

And has anyone thought of a nice way to produce a country drop-down list that is ordered by continents, with the continents actually displayed? i.e. as if we were displaying a subsummary report.

Link to comment
Share on other sites

And has anyone thought of a nice way to produce a country drop-down list that is ordered by continents, with the continents actually displayed? i.e. as if we were displaying a subsummary report.

take a look into conditional value lists

 

OTOH, it would probably make more sense to just list, say, the ten countries we deal with most often ahead of all the rest, with our own country listed first. I'm thinking of something along the lines of adding 1 to a number field every time the country is selected somewhere and having a field that assigns 0 to our own country, 1 to the top ten countries, and 2 to all other countries, so that the sorting could be based on this field first followed by the country name field.

I'm not sure how that could be done with a value list (not saying it's impossible). For a contacts file, I have used a portal view of recent selections. I sort the contacts in the portal by timestamp descending. Everytime a contact is searched for (scripted) the timestamp gets updated, or everytime it is clicked in this portal, the TS is also updated. So the most frequently searched for or selected contacts would always be top of the list.

 

BTW this is an old thread. I would not recommend using the popup script trick above any more. Sorry. If you need to trigger a script from a popup, use a plugin.

Link to comment
Share on other sites

Thanks,

 

Don't know how I landed on a thread this old! Must've clicked through unwittingly. Sorry!

 

Not sure I understand why I should use a plugin but I'll take your word for it. :)

 

I understand conditional value lists, but thinking of screen real-estate makes me want to have a single popup list, not two, with indented labels, e.g.

 

---Europe

Andorra

Liechtenstein

Monaco

San Marino

---Asia

Bhutan

Laos

Nepal

---North America

Canada

Mexico

United States

---Asia Pacific

etc.

 

Still, I've got bigger issues right now. I'll drop this thread.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.



×
×
  • Create New...

Important Information

Terms of Use