Jump to content

This topic is 8112 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Is there a way that I can STOP carriage returns on certain fields? Or at least use Validation (or something else) to provide a message to the user to correct their entry? It is happening on Win system using alpha [ENTER]. This is very annoying mad.gif

Posted

Hi Jeff,

On Windows enter doesn't exit the field ... it just enters a carriage return ... a real pain! I want to STOP it -- So I CAN use Validation to at least flag it for users, right? Then why do I need to write a script? Sorry I don't understand. Thanks for responding, I appreciate your help smile.gif

Posted

Well...with that script you can change the field input whitout the CR -OR- Just make a field thats the sum of all the positionfields. When the user wants to go to the next layout and the total of the sum is > 0 you can hold the user and let him/her change the field!

jeff

Posted

Hi LaRetta!

Set up your field to "Validate by Calculation"

The calculation is:

If(Position(fieldName, "

Posted

Thanks both of you! Okay, so I can use a Validation calc to catch carriage returns in the future! Good! This frustrates me -- I don't want to strip all my fields on a regular basis! smile.gif THANK YOU!

Posted

Thanks Harry! I just got home from work and was re-looking at this issue. Well, even though carriage returns wasn't the reason my billing bombed, I think I want to implement this. I think carriage returns in most fields is trashy!! I just hope it doesn't upset my Users -- ah, well, if it does I can always change it and instead strip returns at night or something. smirk.gif Hey Brian, This is great ... lots of new things to try and learn!! grin.gif HTH

Posted

Well, if you want to get picky, you also need to take into account that PatternCount takes only two arguments, while Position takes 4 arguments. Depending how efficient Filemaker is in evaluating arguments prior to the actual execution of the function, it may actually be faster to use PatternCount, especially if the text string being processed is fairly small. Only testing will tell. tongue.gif

Posted

[chuckle] With most programming languages, that would be a ludicrous suggestion, but with FMP you're probably right... we probably do need to test it to see how large the strings need to be before you overcome the parameter processing!

Posted

A while back, I blindly assumed that the Replace command was faster than running a looping script with a Set Field. Sometimes it is; sometimes it isn't.

This topic is 8112 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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