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.

Conditional "underline" ?

Featured Replies

Hi forum, I'm kind of a newbie, so bare with me....

The problem I'm having is that I need to underline a field value (between 0 and 9) whenever a certain condition occures.

The closest I came (I think) to the solution was to create a dummy table, with 10 fields, with values from 0 to 9, which I underlined "manualy". They store fine, whenever I browse that table, the values are still underlined. But when I, within a script, use the Set Field function to paste the underlined value from the dummy table into the main table, the program does in fact execute the past, but the underline is gone......

Any clues ?

Paste without style tells FileMaker Pro to ignore all text style and formatting associated with the Clipboard contents.

  • Author

Thanks Lee, but how can I paste with style ?

Hi Eric,

Sorry, I didn't give your post a good read. You can not use the Set Field and retain any formatting. FileMaker removes styles in a calculation. You can retain the styles though by using the Copy and paste. Just be sure you do *not* click on Pasting Without Styles, or you will lose your formatting.

HTH

Lee

Hi Eric,

A little more thought on this, I think there is more here than what what I'm seeing. I just reread this again, and you have referred to the values as being between 0 and 9. You also said that you can manually underline the value, indicating they are numbers in a text field, because you shouldn't be able to manually underline a Number in a Number field, So, I'm guessing that these are numbers in a Text Fields here?

The other thing that is confusing to me is, how is this action triggered?

Lee

  • Author

Thanks again, Lee, copying and pasting as we speak ;-). It works !

  • Author

Sorry Lee, I didn't see your 2nd comment in time.

You're right, these are text fields. In fact, at some point I must concatenate these 10 text fields into 1 text field. Ran into the next problem here.....

But as I said, the first step is to underline the fields.

The fields I must underline are actualy refering to other fields, and it's their value that will trigger the underlining. The fields to be underlined (or not) have a value from 1 till 0 (they represent scales, used in the MMPI test, used in psycology). A field must be underlined when the value of the field it refers to is equal or has a diference of 1 of the field that is next in line to. Are you still with me?

This is one step in creating a code, called Hathaway, which is used to group the same kind of patients.

Now, with your help, I'm now able to change a 1 into a "underlined" 1, etc.

But, the next step is to put all the fields next to eachother, into a new text field. And here I ran into the next problem, because if I define this field as a calculation, and use something like field1 & field2 & field3... my underlines are gone again !

Any clues ? Thanks again !

It will all need to be scripted, assuming you're not using version 7. Each field's data will need to be pasted into the main field. A calculation will not work.

  • Author

Thanks, I'm using 5.5. Are you saying this would be easier in version 7 ?

I would create two new calc fields:-

Field1 Case ( Condition,OriginalField,"")

Field2 Case ( Condition,"",OriginalField)

Stack the two field over each other on the layout, but format one of the fields to display underlined. You will need to ensure you select a transparent background for the upper field. This method is fine for displaying data and finds but dosn't allow for data entry. If you need data entry place your original field underneath the two new fields and only allow entry into the original field.

I am not sure about in Filemaker 5.5 but in 7 you can just surround your whole concantenation field with a TextSyleAdd function. You can use this function to underline, bold, make all caps, etc.

It seems to me that this is the easiest way to pull this off in any calculation field.

  • Newbies

how do you create a field w/ drop boxes? AHK I'm so confused! Does anyone want to create this database for me? I'm going crazy!

Format your field in layout mode to be either a list or menu based on the value list you desire.

  • Author

Thanks, I can't find this function in version 5.5, so I guess I've a very good reason to upgrade.....

  • Author

Thanks Robert, this sure looks like a whole new approach ! I'll try this later today. Thanks again.

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.