Print View - InfoPath Dev
in

InfoPath Dev

Print View

Last post 10-17-2005 12:13 PM by Greg Collins. 6 replies.
Page 1 of 1 (7 items)
Sort Posts: Previous Next
  • 10-11-2005 03:44 PM

    Print View

    I have a Infopath form that has a number of views with it. For each of the views I have created a Designated print view. The problem is when ever I choose to print one of my views, the Print View is not printed. Instead the the normal view is printed.

    If I manually select the print view and print, it prints just as I would exp;ect. I have checked the manifest.xml file and for each view it has the corrrect "print view" defined.

    Any suggestions?
  • 10-11-2005 03:54 PM In reply to

    If you go the the properties dialog for your editable views, you can select which view is used as a print view. Perhaps you have already done this. If not, InfoPath does not understand which view you want to use as a print view until you specify it in the properties dialog.

    Greg Collins [InfoPath MVP]
    InfoPath Dev
  • 10-11-2005 05:17 PM In reply to

    I have done this. For the property of each editable view I have set an appropriate print view but this seems to have no effect as the editable view always prints.

    I do have VB code associated with the form and do do a UI.SwitchView to change to the appropriate view. Does this still use the pribt view associated with it?
  • 10-12-2005 04:28 PM In reply to

    In what sense do you use the switch view? To manually switch to the print view somehow? Print views should be automatic. If you just use it for the user to switch between editing views, there should be no issue.

    Try createing a new blank form with 2 views, set one as the print view and do a print preview from the editing view. If this works, then something else is wrong with your form. If it doesn't work, then something is wrong with InfoPath.

    Greg Collins [InfoPath MVP]
    InfoPath Dev
  • 10-13-2005 05:20 AM In reply to

    I have done more experimentation and here is a bit more info. My form actually has about 7 views (not including print views). Depending on data that is entered into the form, I have VB code that does thisXDocument.View.SwitchView to the appropriate view for further data input. Each of the 7 views has a printView property set to the printer friendly view of the data and the same printview name is set for each of the 7 views.

    Here is the inconsistency I am seeing. If I invoke a "Fill In this Form" from Sharepoint the new form does switch to the proper print view. But if I open an existing form and select Print it does not switch to the printview. I do have the option "on version change automatically upgrade" turned on. Any ideas?

  • 10-14-2005 07:23 AM In reply to

    I am reporting that I was able to get this working but I can't explain why. What I did was create a new default view that was in fact a dummy. The OnLoad event did a SwitchView to the the right form. Now everything works just fine. The reason I tried this is when I did an XMLspy of the manifest.xml of the form, it looked like there was some type of hierachy established based on the default view. Maybe something got corrupt in the manifest file and creating the new default caused it to rebuild. In any event this thread is closed. Thanks.
  • 10-17-2005 12:13 PM In reply to

    Thanx for reporting back. I'm glad you got it fixed.

    Greg Collins [InfoPath MVP]
    InfoPath Dev
Page 1 of 1 (7 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.