Maelezo rahisi: “Thamani si kuanguka ndani mbalimbali yanayotarajiwa.”

UPDATE: An anonymous poster left a great comment about internal names. Be sure to read it.

Wakati wa kufanya kazi na kupokea tukio na code nyingine kwamba marejeo SharePoint orodha ya vitu via mfano kitu, Mimi mara nyingi kufanya makosa ili kuzalisha hili kosa katika Runtime:

Hitilafu ya upakiaji na mbio tukio receiver Conchango.xyzzyEventReceiver katika xyzzy, Version = 1.0.0.0, Utamaduni = neutral, PublicKeyToken = 0dc50a750396c3ac. Additional information is below. : Value does not fall within the expected range.

I think this is a fairly generic error that is potentially caused many different ways. Hata hivyo, one simple explanation is that I’m referencing a field incorrectly. If the name of the field is "Due Date", Mimi lazima akifanya marejeo ni kama hii katika receiver tukio:

properties.ListItem["Due Date"]

Wakati mimi misspell au kutumia vibaya wakati kesi referencing shamba, SharePoint generates the above mentioned runtime error. Kwa mfano, hii ni sahihi:

properties.ListItem["due Date"]

</mwisho>

Kujiunga na blog yangu.

Tags technorati:

Wazo moja juu ya "Maelezo rahisi: “Thamani si kuanguka ndani mbalimbali yanayotarajiwa.”

  1. R Sanjaykuma Patel

    Nakubaliana na paul lakini i pia nataka kuongeza kitu kwa ajili ya ubaguzi huu.
    Wakati mwingine Jina la uwanja ni tofauti na Uwanja wa Ndani Jina katika orodha yao ili kujaribu kupata shamba kwa kutumia Jina la uwanja katika mtindo kitu inatupa ubaguzi hapo juu. Ili kutatua tatizo hili siku zote kujaribu kupata mashamba yao kwa kutumia majina ya Ndani.
    Jinsi gani unaweza kupata majina ya ndani ya mashamba?
    1) Go To Sharepoint List. Go to New | Mpya Item.
    2) Mpya fomu Item itakuwa visas. Haki click kwenye fomu na bonyeza Chanzo View. Tafuta kwa ajili ya Jina Field Ndani katika utaratibu wa kufunguliwa HTML. Utapata Field Internal Jina pamoja na Jina Field.

    Kujibu

Kuondoka Reply

Anwani yako si kuchapishwa. Mashamba required ni alama *