문제

when i try to add listitem to custom list by CSOM there is a problem in getting the name of fields field name in the list is"Pieces Unaccompanied Hold Baggage(Rush)" ,but when i try to add item ,error fires that the field does not exist

code:

oListItem.set_item('Pieces Unaccompanied Hold Baggage(Rush)', "value");

도움이 되었습니까?

해결책

You got an extra ")" in your code. It should be this way:

oListItem.set_item('Pieces Unaccompanied Hold Baggage(Rush)', "value");

But, in oListItem.set_item() method, the first parameter shoult be the INTERNAL NAME of the field. You will find the internal name in the URL when you open the field (column) settings. So it should be

oListItem.set_item('InternalName', value)
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top