Expand my Community achievements bar.

setFocus question

Avatar

Level 3

When I setFocus to a field, it highlights all of the text in that field. Is there any way around that? I would ideally like the cursor to just fall at the end of the text in that field so the user could just keep typing.

- Nathan

2 Replies

Avatar

Former Community Member

I do not know of a way to do that .....the setFocus puts focus on the field and is set to highlight all of the text in the field.

Paul

Avatar

Level 2

Use this,

xfa.host.setFocus(F.P1.NAME);

give the field that needs the focus to cursor on.

Hope it helps for you. Let me know, if it works..

All the best