Skip 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.

Custom Field Validation if more that x Char

Featured Replies

Hello, 

i have a custom dialog, i need to put 4 character and then click ok

could i make the custom dialog box validate automatically if i put 4 characters ? 

Thanks you

 

Screen Shot 2016-03-07 at 10.48.55.png

if you need to validate data before processing i would not use a custom dialog.

I would use a popover and build my own custom dialog because with the popover button you have greater ability to customize the user experience.

Edited by Kris M

  • Author

Hi Kris M, thanks you for the answer, 

i try right now with the popover but i can't use a script with it ?

right now with dialog box it s working like this  i click to a "button x" > script load captcha picture from webviewer >show it bigger> open dialog box> I put the character > I click ok >script put it in the field captcha of webviewer> script simulate click on "validate" of the webviewer > done

what i would like is that the click on OK of dialog  box will be done automatically if i put 4 characters. 

you think it could work with popover ?

thanks you

3 hours ago, ibobo said:

could i make the custom dialog box validate automatically if i put 4 characters ? 

Yes, of course you can. There are several ways you could set this up, depending on what you want to happen in each case. Here's a simple example:

...
If [ Get ( LastMessageChoice ) = 1]
  If [ Length ( YourTable::UserInput ) = 4 ]
    # PROCEED
  Else
    # ERROR
  End If
End If
...

 

  • Author
5 hours ago, comment said:

Yes, of course you can. There are several ways you could set this up, depending on what you want to happen in each case. Here's a simple example:


...
If [ Get ( LastMessageChoice ) = 1]
  If [ Length ( YourTable::UserInput ) = 4 ]
    # PROCEED
  Else
    # ERROR
  End If
End If
...

 

Thanks you Comment, 

it works ;) but i still need to click on "OK" button, what i would like is that it doing it, it self since i put 4 character, to avoid the click with the mouse. 

This example have nothing to do with filemaker but just for understand :  on google.com  you dont need to click on "research" button, it doing it self since i writing something in safari or firefox. 

:) 

9 minutes ago, ibobo said:

i still need to click on "OK" button, what i would like is that it doing it, it self since i put 4 character, to avoid the click with the mouse.

You cannot do that with custom dialog. Once you have invoked a custom dialog, it will stay up until you click one of the buttons (or press the equivalent key).

You can do that by having the user type directly into a field, and using a script triggered OnObjectKeystroke.

  • Author

Hello, i tried yesterday  during few hours to make it work, and i couldn't, maybe my skills is not enough >< 

 

Here's a very simple example to get your started.

In fact it's too simple, because it counts navigational keystrokes such as Backspace or Enter as characters.

OnObjKeystroke.fp7

On second thought, this might be much better suited to your purpose:

OnObjModify.fp7

Edited by comment

  • Author

GENIAL ! :) thanks you, it s work perfectly !! :cool:  

Have a good day Mister Comment B)

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Search

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.