Problems with fields

PDF-XChange Viewer SDK for Developer's
(ActiveX and Simple DLL Versions)

Moderators: TrackerSupp-Daniel, Tracker Support, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

KennethAa
User
Posts: 18
Joined: Tue Jun 17, 2008 3:37 am

Problems with fields

Post by KennethAa »

Hi,

Been working steadily with integrating your PDF viewer into our application, but some issues has crept up.
  • - When setting the value of the focused field, the value is not displayed until the field looses focus.
  • - Shift + Tab does not move backwards
  • - Control + A cannot select all text in a field
I also have a request for an extension to the pdf standard with regards to field support: would it be possible to get/set the selected text within the field, not the whole text?

With Regards,
Kenneth Aafløy
in3 support as
User avatar
Ivan - Tracker Software
Site Admin
Posts: 3556
Joined: Thu Jul 08, 2004 10:36 pm
Location: Vancouver Island - Canada

Re: Problems with fields

Post by Ivan - Tracker Software »

- When setting the value of the focused field, the value is not displayed until the field looses focus.
Do you set field's value programmatically when it is in focus ?
- Shift + Tab does not move backwards
- Control + A cannot select all text in a field
Will add into the next build.
I also have a request for an extension to the pdf standard with regards to field support: would it be possible to get/set the selected text within the field, not the whole text?
Again, it should work when field is in focus and edited ?
Tracker Software (Project Director)

When attaching files to any message - please ensure they are archived and posted as a .ZIP, .RAR or .7z format - or they will not be posted - thanks.
KennethAa
User
Posts: 18
Joined: Tue Jun 17, 2008 3:37 am

Re: Problems with fields

Post by KennethAa »

Do you set field's value programmatically when it is in focus ?
Again, it should work when field is in focus and edited ?
Yes, since this is used to fill data from a database into the form. I've got a workaround right now, that focuses another field, before setting the value, and moving the focus back, but then the document will also scroll in certain circumstances.
Will add into the next build.
Thanks :)

One more thing that would be really nice when editing fields is support for undo/redo typing.

Kenneth
KennethAa
User
Posts: 18
Joined: Tue Jun 17, 2008 3:37 am

Re: Problems with fields

Post by KennethAa »

Ivan - Tracker Software wrote:
- Shift + Tab does not move backwards
- Control + A cannot select all text in a field
Will add into the next build.
There seems to be some problems with keys in the latest build as well.

If I open the viewer as a standalone program, CTRL+[O|W|...] keys will not work when a field has focus, the only keys that work is CTRL+[A|C|V|X]. Also Shift + Tab still moves forward.

If I open the control within the test projects PDFViewerActiveXTest*, even CTRL+[A|C|V|X] is not functioning.

Edit: Just read the other post about keyboard shortcuts, and General.AllowAllAccelerators = True fixes the CTRL+[A|C|V|X] issue in ActiveX.

This was tested with build 40.5, but I have not checked if this was the case in earlier builds also.

With Regards,
Kenneth
Fanski
User
Posts: 33
Joined: Tue Apr 17, 2012 10:33 am

Re: Problems with fields

Post by Fanski »

I have the same problem.

When setting the value of a focused field, the value is not displayed until the field looses focus.
I set the value programmaticaly. ('this.getField("TestFieldName").value = ...')
The Version of the Viewer is 2.5 Build 214.1

Is ther a solution for this problem?

Kind Regards
Peter
Fanski
User
Posts: 33
Joined: Tue Apr 17, 2012 10:33 am

Re: Problems with fields

Post by Fanski »

I found something that works for me:

mAxCoPdfxCview.FlushDocument(ActiveDocId, 0);

This deselect the form field and display the value.

Because i dont need the field to be selected after the value has been written, its ok for me.
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17960
Joined: Mon Jan 12, 2009 8:07 am
Location: London

Re: Problems with fields

Post by Tracker Supp-Stefan »

Glad this works for you Peter!

Cheers,
Stefan
dconner
User
Posts: 28
Joined: Fri Feb 07, 2014 10:27 pm

Re: Problems with fields

Post by dconner »

Hi All,

It appears that our company may have identified two different bugs pertaining to text fields:

Bug #1:

I open a PDF document, select the text box tool from the toolbar, and then create a text box on the form. I put text in the text box WITHOUT LOSING FOCUS and press the red X on top of the form.

The Result: Changes to the PDF aren't registered and the form closes without saving changes.

The Fix:

int aid = 0;
axCoPDFXCview.GetActiveDocument(out aid);
if (aid > -1) axCoPDFXCview.FlushDocument(aid);


Bug #2:

If I open a PDF document, enter text in the first embedded form field area (a standard fillable form field), DO NOT tab off, then close the document, it will not save the changes.


The Fix:

I have tried to use FlushDocument() but this doesn't seem to resolve the issue at all. Has this issue already been resolved? I can't seem to make it work. I'm using version 2.5.315.0 of PDFXCview.exe.

Thank you.
dconner
User
Posts: 28
Joined: Fri Feb 07, 2014 10:27 pm

Re: Problems with fields

Post by dconner »

Hi All,

I have confirmed the issue to be a bug in our own software! I have confirmed that FlushDocument() works in this instance as well (for Bug #2).
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17960
Joined: Mon Jan 12, 2009 8:07 am
Location: London

Re: Problems with fields

Post by Tracker Supp-Stefan »

Lovely to hear that the problems are resolved dconner!

Cheers,
Stefan