Does PDF Viewer control have some kind of a "Loaded" event RRS feed

  • Question

  • My implementation is as follows:

    1. User clicks on a TextBox for input

    2. I handle the TextBox's Enter event to load a corresponding PDF file into a PDF Viewer control on the form.

    3. Since the TextBox has already lost focus, refocus the TextBox at this step.

    However, the PDF file loading seems to be a little slow so when I try to call Focus() on the TextBox, it fails to regain focus every time.

    Does anyone know whether the PDF Viewer control fires some event to signal that it has already finished loading the requested PDF file so I can regain focus on the TextBox?

    • Edited by happ-bo Thursday, August 3, 2017 5:26 AM
    • Moved by Stanly Fan Wednesday, August 16, 2017 7:59 AM from windows forms general
    Thursday, August 3, 2017 5:22 AM

All replies

  • Have you tried to select the control in Form Designer, then check the list of available events in the Properties panel, clicking the Events icon?

    You can also type in your code the name of the variable, then ‘.’. IntelliSense will suggest the list of members and events.

    Thursday, August 3, 2017 5:48 PM
  • I have already tried as you said but could not find such an event.

    Is there any other way to know when the file loading completes?

    Friday, August 4, 2017 7:48 AM
  • there is no such PDF viewer control in WinForms.

    you need to contact the author of the undisclosed third party PDF viewer control to write such an event if the event you want does not exist. 

    Visual C++ MVP

    • Proposed as answer by Stanly Fan Monday, August 14, 2017 4:06 AM
    Wednesday, August 9, 2017 2:45 AM
  • Hi happ-bo,

    Just as Sheng Jiang said, there is not a PDF Viewer control in MS Winform, so where do you get this control? You can contact the author to ask your question.



    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, August 14, 2017 4:09 AM