This topic contains 1 reply, has 1 voice, and was last updated by ALOK binwal 7 years ago.
-
AuthorPosts
-
November 10, 2017 at 11:25 am #16409
Hi I am updating the journal entry line using suite talk api but facing this issue-: You do not have permissions to set a value for element line.line due to one of the following reasons: 1) The field is read-only; 2) An associated feature is disabled; 3) The field is available either when a record is created or updated, but not in both cases.
This is my sample code:
<p style=”text-align: left;”> JournalEntry journalEntry = new JournalEntry();</p>
<p style=”text-align: left;”> journalEntry.internalId = “353”;</p>
<p style=”text-align: left;”></p>
<p style=”text-align: left;”> JournalEntryLine journalEntryLine = new JournalEntryLine();</p>
<p style=”text-align: left;”> journalEntryLine.line = 1;</p>
<p style=”text-align: left;”> journalEntryLine.lineSpecified = true;</p>
<p style=”text-align: left;”></p>
<p style=”text-align: left;”> List<CustomFieldRef> customfieldList = new List<CustomFieldRef>();</p>
<p style=”text-align: left;”> BooleanCustomFieldRef fieldRefIsDuplicate = new BooleanCustomFieldRef();</p>
<p style=”text-align: left;”> fieldRefIsDuplicate.internalId = “448”;</p>
<p style=”text-align: left;”> fieldRefIsDuplicate.value = true;</p>
<p style=”text-align: left;”></p>
<p style=”text-align: left;”> customfieldList.Add(fieldRefIsDuplicate);</p>
<p style=”text-align: left;”> journalEntryLine.customFieldList = customfieldList.ToArray();</p>
<p style=”text-align: left;”></p>
<p style=”text-align: left;”> List<JournalEntryLine> journalEntryLineList = new List<JournalEntryLine>();</p>
<p style=”text-align: left;”> journalEntryLineList.Add(journalEntryLine);</p>
<p style=”text-align: left;”></p>
<p style=”text-align: left;”> JournalEntryLineList objJournalEntryLineList = new JournalEntryLineList();</p>
<p style=”text-align: left;”> objJournalEntryLineList.line = journalEntryLineList.ToArray();</p>
<p style=”text-align: left;”></p>
<p style=”text-align: left;”> journalEntry.lineList = objJournalEntryLineList;</p>
<p style=”text-align: left;”> WriteResponse saveResponse = new WriteResponse();</p>
<p style=”text-align: left;”> saveResponse = nsServiceBridge.UpdateRecords(journalEntry);</p>
-
November 14, 2017 at 3:47 am #16410
-
AuthorPosts
You must be logged in to reply to this topic.