Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

Format a field as the user types

Narzerusz
Level 1
Level 1

Hello everyone. I've been trying to find a nice way to format a field while the user is typing.

For example:
Raw input: 123456
Expected Format: 123.456

So, when the user types 1234 it should instantly change to 1.234

I've juggled a bunch of hacky workarounds such as unfocusing and re-focusing the field but this leaves the field's text selected.  Another thing I tried was to simply set the rawValue of the input to a formatted version of the text, but nothing happens (I'm guessing LiveCycle Designer dissalows fields content to be changed while they are focused)


Any ideas?

Thanks.

1 Accepted Solution
MinusZero
Correct answer by
Level 7
Level 7

This works only when the field is exited, but you could just use a Pattern.

Click Patterns

1460925_pastedImage_0.png

Select a Pattern

1460926_pastedImage_1.png

Click OK

Type in your field

1460927_pastedImage_2.png

When your field is exited

1460928_pastedImage_3.png

View solution in original post

1 Reply
MinusZero
Correct answer by
Level 7
Level 7

This works only when the field is exited, but you could just use a Pattern.

Click Patterns

1460925_pastedImage_0.png

Select a Pattern

1460926_pastedImage_1.png

Click OK

Type in your field

1460927_pastedImage_2.png

When your field is exited

1460928_pastedImage_3.png

View solution in original post