June 22, 201015 yr 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! :
June 22, 201015 yr 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.
July 7, 201015 yr Author 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!
July 8, 201015 yr 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.
July 8, 201015 yr Author 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
Create an account or sign in to comment