Welcome to MSDN Blogs Sign in | Join | Help

InfoPath Team Blog

Tips and tricks to get the most out of Microsoft InfoPath

News

  • For questions, comments, and feedback please use the public newsgroup: microsoft.public.infopath
    This is provided "AS IS" with no warranties, and confers no rights. Use of included script samples and forms are subject to the terms specified in the Terms of Use.
Manually setting the default print margins for an InfoPath form

This tip applies to form designers who want to change the default print margin on a form using InfoPath 2003 since the Service Pack 1 release allows designers to change these properties in design mode from the View Properties dialog.

So, if you do not have the Service Pack 1 installed you can still accomplish this by following these steps:

  1. Open the form you want to modify in design mode
  2. From the File menu, chose Extract Form Files…
  3. Save the document to a folder of your choose. A new, empty folder will allow you to find files easier.
  4. Locate the folder where you save the files.
  5. Right-click on the file manifest.xsf and choose Open-With…Notepad
  6. There will be an <xsf:view> element for each view. Locate the view you would like to define margins for.
  7. Insert the following XSF definition for margins (the view elements will already exist):

<xsf:view ...>

<xsf:printSettings

marginUnitsType="in"
leftMargin="0.25"
topMargin="0.5"
rightMargin="0.25"
bottomMargin="0.5">

</xsf:printSettings>

<xsf:view>

  1. Save and close manifest.xsf
  2. Right click again on manifest.xsf and choose Open in Design Mode…
  3. From the InfoPath design mode, Publish your form so that users can print using your new margins!

Notes: marginUnitsType can contain either in or cm. The rest of the margins are interpreted based on those unit types.

Posted: Thursday, March 18, 2004 5:39 PM by infopath

Comments

Enjoy Every Sandwich said:

You have been Taken Out! Comments about your posting in this link. Thanks!
# March 18, 2004 11:06 PM
Anonymous comments are disabled
Page view tracker