To Assign Seq No.s to Invoice
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Chulette..chulett wrote:So... you don't feel comfortable enough with the concept of stage variables to adapt the code for this 'new' requirement, so didn't try? Or you've tried and couldn't make it work?
I am fully not understand stage variable..if i am not asking too much then could you please give me the code for this also.
Thanks in advance
Input: InvNo and RecType
Create 3 stage variables:
svNewInvNo (init val=""): If input.InvNo=svInvNo Then 0 Else 1
svInvNo (init val=""): input.InvNo
svSeqNo (init val=0): If svNewInvNo Then 1 Else (If input.RecType="605" Then svSeqNo+1 Else svSeqNo)
Output: InvNo = input.InvNo
RecType = input.RecType
SeqNo = svSeqNo
Hope this works for you.
shepli
Create 3 stage variables:
svNewInvNo (init val=""): If input.InvNo=svInvNo Then 0 Else 1
svInvNo (init val=""): input.InvNo
svSeqNo (init val=0): If svNewInvNo Then 1 Else (If input.RecType="605" Then svSeqNo+1 Else svSeqNo)
Output: InvNo = input.InvNo
RecType = input.RecType
SeqNo = svSeqNo
Hope this works for you.
shepli
Shepli..Thanks for your reply.shepli wrote:Input: InvNo and RecType
Create 3 stage variables:
svNewInvNo (init val=""): If input.InvNo=svInvNo Then 0 Else 1
svInvNo (init val=""): input.InvNo
svSeqNo (init val=0): If svNewInvNo Then 1 Else (If input.RecType="605" Then svSeqNo+1 Else svSeqNo)
Output: InvNo = input.InvNo
RecType = input.RecType
SeqNo = svSeqNo
Hope this works for you.
shepli
Could you please suggest me the code for my previous post..510 and 520 records
edward_m, there are several codes provided by our posters. Shepli gave you code for each scenario. See what works and if you are not getting the desired result, let us know what output you are getting for what code.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.