June 2, 200322 yr Newbies Hi, I am new with FM. Can anyone help me with this problem? I have a field that is basically a list of categories. Each record belongs to one of the categories. I have a button for each category. When the users click on a button, it finds and shows all the records for that category. Now the problem is for some categories there are no records. It is very annoying for the users when they click a button and get "no found records" message. I want to display the number of records for each category next to the button for that category so that the users don't have to go in if the number of records is 0. Does anyone have any ideas on how to do this? I guess I might have to use self-join portal, but could not figure out the best way to do it. Thank you in advance.
June 2, 200322 yr Well, Count(your relationship::record_Id) should give you the current records for each category. According to your structure, you may need either : - a self-relationship category::category - a set of relationship g_category1::category, g_category2::category2, where the g_category is a global field populated with the category "content". Then, Count(your relationship::Record_ID) should give you the current count of each category. Attached to a button, your script could look like If (Is Valid(your relationship) Go to related records (show only) Else Show message (there are no match)
Create an account or sign in to comment