locked
value at index 0 in picklist RRS feed

  • Question

  • Whenever we add a value in the picklist in the picklist attribute, it starts with index 1.

    What is the value at index 0?

    Suggestion?

    Friday, July 24, 2009 11:01 AM

Answers

  • Microsoft is starting to allow the values to be entered from index 1 onwards , and using index 0.
    its like you have an array , you can start it from index 0 or you can also start it from index 1, its your choice.

    OR it also may be to differentiate between picklist and bit field , as you know bit field starts from index 0, and picklist starts from Index 1.

    so if you try to access index 0 of picklist you may be undefined or null error.

    Vilas http://www.mscrm-vilas.blogspot.com
    • Proposed as answer by vilas_mscrm Sunday, July 26, 2009 9:52 PM
    • Marked as answer by arjunrules19 Monday, July 27, 2009 2:59 AM
    Sunday, July 26, 2009 9:52 PM

All replies

  • Hi Arjun,

    It should be null or undefined if you access it via JavaScript.


    Regards,
    Chinmay
    http://metrix.blogspot.com
    Friday, July 24, 2009 11:10 AM
  • Microsoft is starting to allow the values to be entered from index 1 onwards , and using index 0.
    its like you have an array , you can start it from index 0 or you can also start it from index 1, its your choice.

    OR it also may be to differentiate between picklist and bit field , as you know bit field starts from index 0, and picklist starts from Index 1.

    so if you try to access index 0 of picklist you may be undefined or null error.

    Vilas http://www.mscrm-vilas.blogspot.com
    • Proposed as answer by vilas_mscrm Sunday, July 26, 2009 9:52 PM
    • Marked as answer by arjunrules19 Monday, July 27, 2009 2:59 AM
    Sunday, July 26, 2009 9:52 PM
  • Thanks!!
    Monday, July 27, 2009 3:00 AM