Highlighted

setFocus Problems When Using Older Adobe Reader Versions

Avatar

Guest

13-10-2008

In my Validate Event using Adobe Reader 8.1.0 or higher, I'm using:



xfa.host.setFocus(); // Clear focus operation

xfa.host.setFocus(this); // Set cursor back to current field



This sets the cursor back to the current field when bad data is entered and works for both the Tab and Enter key. It highlights the bad data.



But this does not work correctly when using Adobe Reader 8.0 and 7.0.x.

Problems I had with these older Readers regarding setFocus:



1. Enter key does not fire setFocus, only Tab works

2. setFocus goes into loop when using a Date/Time field and Reader 7.0.x

3. xfa.host.setFocus() does not clear focus operation like Reader 8.1.0+



Anybody else had similar problems or know a workaround?



Thanks,

Ron

Replies

Highlighted

Avatar

Guest

14-10-2008

I looked at this again today and discovered a difference:



READER 7.0.x:



On Date/Time field, Validate fires on exit even if no change was made to the data.



On other type fields, Validate fires on exit when data was changed.



READER 8.0 and up:



On Date/Time field and other type fields, Validate fires on exit when data was changed.



I read in the Livecycle reference manual that the Validate event is supposed to fire on exit only when there is a change to the data. So does the older Acrobat Reader versions have a bug with regard to this?



Any ideas and how to get around this bug?