locked
Format SharePoint Field in Word Template RRS feed

  • Question

  • Hi, I'm having difficulties formatting SharePoint field in a word template.  On the SharePoint list I have a decimal field type with two decimal places.  When I open the Word document the field is formatted as follows:

    SharePoint Word

    40.00 40

    40.10 40.1

    40.12 40.12

    I want the Word document to display the same as SharePoint does.  Is there a way to change the output display, some kind of formula or to string?  Thanks,

    Dan

    Wednesday, December 11, 2013 5:15 PM

Answers

All replies

  • You could add a numeric picture switch to the field in Word. To do this:
    • select the field;
    • press Shift-F9 to reveal the field coding. It should look something like {DOCPROPERTY MyData};
    • add the numeric picture switch to the field, thus - {DOCPROPERTY MyData \# 0.00};
    • position the cursor anywhere in this field and press F9 to update it.

    Cheers
    Paul Edstein
    [MS MVP - Word]

    • Marked as answer by TylorWang Wednesday, December 18, 2013 1:35 AM
    Thursday, December 12, 2013 3:11 AM
  • For cross-posting etiquette, please read: http://www.excelguru.ca/content.php?184

    Cheers
    Paul Edstein
    [MS MVP - Word]

    • Marked as answer by TylorWang Wednesday, December 18, 2013 1:35 AM
    Friday, December 13, 2013 9:31 AM
  • If you are just looking to display the value, the following may help:

    http://answers.microsoft.com/en-us/office/forum/office_2010-word/word-2010-quick-part-document-property-formatting/53ad12d2-2843-402a-815d-e97c72f05d03

    However, if you need the value to be updateable in the content control, things become much harder & will almost certainly require some programming.

    I'll have another look at this, since it has been a while.


    Peter Jamieson

    • Proposed as answer by Peter Jamieson Wednesday, December 18, 2013 5:10 PM
    Friday, December 13, 2013 9:35 AM
  • Thank you!!! I searched for a long time and couldn't find this.  Got it working now!
    Friday, December 13, 2013 3:37 PM