Page 1 of 1

Add CommentLine to a PO

PostPosted: Mon Feb 26, 2018 3:01 pm
by OliverYan
Hi,

I have created a plugs to insert a commentline to PO, the key parameter NewKey is now a Object, not a string value. how/what value can I assign value to this object?

Here is my code,

Dim oNewKey=New Object()

If CommentLineText<>"" Then
purchaseorder.Lines.AddCommentLine(CommentLineText,oNewkey,0)
End If

no error raised when I compile this code. but when I run it in PO creation, it crash Jiwa.
Would you please help?

Thanks,
Oliver

Re: Add CommentLine to a PO

PostPosted: Mon Feb 26, 2018 3:05 pm
by Scott.Pearce
Declare newKey as a string. i.e.

Code: Select all
Dim newKey As String = ""

If CommentLineText<>"" Then
    Lines.AddCommentLine(CommentLineText, newKey, 0)
End If


newKey is a return parameter, after the call it will contain the key to the new line in the lines collection.

Re: Add CommentLine to a PO

PostPosted: Mon Feb 26, 2018 3:12 pm
by OliverYan
Hi Scott,
Thanks for your really quick reply.

I just changed as your sample. but get same result as before.
my Jiwa version is 7.00.175.

any suggestion?

Thank you very much.
Oliver

Re: Add CommentLine to a PO

PostPosted: Mon Feb 26, 2018 3:14 pm
by Mike.Sheen
OliverYan wrote:my Jiwa version is 7.00.175.

any suggestion?


Hi Oliver, You need to ask this question in the Version 7 forum. This is the version 6 forum.

Mike

Re: Add CommentLine to a PO

PostPosted: Mon Feb 26, 2018 3:18 pm
by OliverYan
Hi Scott,
sorry for that. :)
I just repost on Jiwa 7 forum.

Thanks,
Oliver