This topic contains 3 replies, has 0 voices, and was last updated by k_dunc 5 years, 9 months ago.

  • Author
    Posts
  • #21940 Score: 0

    SBatten
    • Contributions: 0
    • Level 1

    Hi

    I have written a Suitelet that displays a list of invoices. When the user clicks submit, I need to update each invoice with the date the invoice is chased.

    I have got the below code and am getting an error message of 'ID'.

    Code:
    nlapiSubmitField('invoice', internalID, 'custbody_copy_last_sent_date', todayDate);
    Any ideas what is wrong with the above code? This code does work fine for a credit memo but not for invoices.

    Many thanks

    Sam
    This is a cached copy. Click here to see the original post.

  • #21941 Score: 0

    k_dunc
    • Contributions: 0
    • Level 1

    Hi Sam,

    What's the actual error message you're getting? What format is 'todayDate' and 'custbody_copy_last_sent_date'? I just wonder perhaps, if you need to change 'todayDate' to 'nlapiDateToString(todayDate)'?

    Cheers,

    Kirk.

  • #21942 Score: 0

    SBatten
    • Contributions: 0
    • Level 1

    Hi Kirk

    Many thanks for the reply.

    custbody_copy_last_sent_date is date field and the variable todayDate returns 29/06/2018. This code works for credit memos so cannot work out why it doesn't also work for invoices.

    Thanks

    Sam

  • #21943 Score: 0

    k_dunc
    • Contributions: 0
    • Level 1

    So the nlapiDateToString(todayDate) didn't help either?

    What's the error message that you're getting?

    You're not attempting to update invoices in closed periods are you?

You must be logged in to reply to this topic.