Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

Hi everyone.. this is another thing that's been im my mind but not sure if I can implement it or not-

I want to incorporate a script with a pop-up error/reminder message for the data input. For example, when people input the address in the address field, I want to be able to detect if they input something like "Aparment" "Unit" or "Suite" (I assume this part can be done by a script) and if they do I want to automatically pop up an error message to remind them to input "Apt." instead...

Can I do that in FM?

Thanks a lot! :

Posted

This could be done with field-level validation, but it would probably be nicer with a scripted process.

Hold the user in a loop to keep their attention:

Allow User Abort [off]

...

Loop

Pause/Resume Script [indefinitely]

Exit loop if [ patterncount( field ; "apartment" ) = 0 and ... etc ]

Beep

Show Dialog [ Change apartment ]

End Loop

Watch that loop and ensure you have a valid exit condition otherwise you'll be in there for a while. Backup frequently while testing. In fact, set user abort on while testing and switch off when it's working.

  • 2 weeks later...
Posted

Hi Vaughan,

Thank you for the information a while ago. I tried the logic in my script, but ran into some issues. I basically wrote all the cases of the correct address input in the "exit loop if" line and filled the "show dialog" line with the warning message. But during my testing, the script will be paused and the error message will show up no matter what I input...

Any ideas here? Thanks a lot!

Posted

Post what you've done, especially the Case statement in the exit loop.

Posted

You need to post the expression that's in the Exit Loop step.

Also realise that that unless *all* the criteria are met the user will be kept in the loop.

Posted

this is my script in the Exit loop which includes all the "messed up" input cases

PatternCount(HouseHolds::Address;"E")=0 and PatternCount(HouseHolds::Address;"E.")=0 and PatternCount(HouseHolds::Address;"W")=0 and PatternCount(HouseHolds::Address;"W.")=0 and PatternCount(HouseHolds::Address;"Ave")=0 and PatternCount(HouseHolds::Address;"Avenue")=0 and PatternCount(HouseHolds::Address;"St")=0 and PatternCount(HouseHolds::Address;"Street")=0 and PatternCount(HouseHolds::Address;"st")=0 and PatternCount(HouseHolds::Address;"street")=0 and PatternCount(HouseHolds::Address;"Cres")=0 and PatternCount(HouseHolds::Address;"Crescent")=0 and PatternCount(HouseHolds::Address;"Road")=0 and PatternCount(HouseHolds::Address;"Rd")=0 and PatternCount(HouseHolds::Address;"Boulevard")=0

This topic is 5252 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.