Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

I have two fields that I would like to compare, and if the same change the text colour to highlight the field.

My code is, however it does not work. Both fields are numbers, and if I substitute a number for "{FMP-Field:Currentday}" it works fine! My code is;

<FONT [FMP-IF: Day5.eq. {FMP-Field:Currentday}] COLOR="#ff3300"

[/FMP-IF]> [FMP-FIELD: Day5]</FONT>

Using Mac 9.2, FM 4.1.

thanks

ger

Hi, you can use an FMP-Field like that in an "IF" and it will work fine. You can also deliver all kinds of HTML as a result, too so unless I've really missed something in your code I can only suggest that it's a function of using FMP4.

This one works for me in FMP5 and has html code, FMP fields an else and all kinds of junk in it:

[FMP-IF: CurrentDate.lte.{FMP-Field:end}]

<A HREF="http://mydomain.com/holidays/FMPro?-db=thedatabase&-format=record_detail.htm&-error=search_error.htm&-lay=layout1&-op=eq&record_number=[FMP-FIELD:record_number]&-find"><FONT SIZE="-2" FACE="verdana,arial,geneva,sansserif" COLOR="#333333"><B>[FMP-FIELD: start][FMP-FIELD: am_pm]</B></FONT></A>[FMP-ELSE]

<FONT SIZE="-2" FACE="verdana,arial,geneva,sansserif" COLOR="#333333"><B>[FMP-FIELD: start][FMP-FIELD: am_pm]</B></FONT>

[/FMP-IF]</P>

Can I suggest a workround to get it going: Create a calculation field in Filemaker to do the work - like If(field1=Field2,"#FF0000","#FFFFF") - and just deliver that. The one below colours a table row, but it's the same principle:

<TD WIDTH=50 BGCOLOR="#[fmp-field:colourfield]">

The advantage here is that you can store your calculations in the Database, rather than having to do them on the fly. This is a lot quicker, especially in FMP4.

regards, Jeff

Jeff is absolutely right.

I am doing everything like that in FM and then I use the result on web.

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.