FMPRO-L Archives

February 2011, Week 1

FMPRO-L@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Jonathan Fletcher <[log in to unmask]>
Reply To:
FileMaker Pro Discussions <[log in to unmask]>
Date:
Fri, 4 Feb 2011 15:44:36 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (48 lines)
Why not just an autoenter calc...


Trim ( Substitute ( Author First ; "¶" ; " " ) )


...and take care of it for them?
 



On Feb 4, 2011, at 3:24 PM, Richard S. Russell wrote:

> On 2011 Feb 4, at 10:25, Rick O'Quinn wrote:
> 
>> I've got a few fields that I need to keep to one line, but not one word. Most are First Name, Last Name fields. I want to make sure users can't enter a carriage return OR any other random characters, such as another name. BUT entering 2 or more words (names) on one line is okay.... 
>> 
>> Is there an easier way?
> 
> 
> I offload the responsibility onto the person doing the data entry by using (always) "Validate by Calculation" and this formula:
> 
> PatternCount ( Author First; "¶" ) = 0 and 
> Left ( Author First; 1 ) ≠ " " and 
> Right ( Author First; 1 ) ≠ " "
> 
> with the following error message on failure:
> 
> "Author First" may not contain a return character or begin or end with a space.
> 
> I use a similar validation in lots of other places where this kind of error is likely to crop up.

--
Jonathan Fletcher
FileMaker 9 & 10 Certified Developer

Fletcher Data Consulting
[log in to unmask]
http://www.fletcherdata.com
502-509-7137

Kentuckiana's FileMaker Users Group
Next meeting: February 22, 12:00 pm to 3:00-ish
Special Location! Special Program!
Info & RSVP: http://fmpug.com/scheduleMeetings.php
Listserv signup: http://fmpug.com/mailman/listinfo/louisville_fmpug.com
Blog: http://www.kyfmp.com

ATOM RSS1 RSS2