Fieldtype Number without Commas RRS feed

  • Question

  • Dear NG

    We have a problem with a custom field (Type Number).

    <Field Name="MyNumber" ID="{CA5CAA08-D041-4b16-9A3B-12DD844CB376}"
    StaticName="MyNumber" DisplayName="My-Number" Group="ABC Fields" Type="Number" SourceID="http://schemas.microsoft.com/sharepoint/w3"
    Min="1" Max="99999" Commas="false" Decimals="0" />

    When we are using this definition, the value will be displayed as 12345.0000000000, when we are using 12345 as input value.

    My question is: How can we display it only as 12345 without "0 - Zeros" and comma?

    It is for us not an option to define the type as integer, because Information Panel in Office Product (Word, Excel etc.) can't display an editbox in editmodus. The Editbox is disabled if we want to use type as integer.

    Best regards,
    Ozgur Aytekin


    Friday, January 29, 2010 12:28 PM


All replies

  • You can use the "Integer" as your type to replace the "Number". Number is float-type.
    Allows for positive or negative integer values. The Commas and NegativeFormat attributes are used to specify integer formatting.

    Field Element (List - Definition)(http://msdn.microsoft.com/en-us/library/ms437580.aspx)
    Cogito, ergo sum.
    • Marked as answer by Chengyi Wu Friday, February 5, 2010 1:57 AM
    Tuesday, February 2, 2010 2:42 AM
  • We had the same problem and we are using integer fields. But there is next problem we have.
    Integer fields are read only in document information panel (MS-Word).

    Any ideas how we can make those fields editable?

    Best regards
    Saturday, February 13, 2010 5:58 PM