Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

this is not a issue , according to my understanding #54

Open
Sajjad-Ali-Logiciel opened this issue Apr 5, 2023 · 1 comment
Open

this is not a issue , according to my understanding #54

Sajjad-Ali-Logiciel opened this issue Apr 5, 2023 · 1 comment
Labels

Comments

@Sajjad-Ali-Logiciel
Copy link

Sajjad-Ali-Logiciel commented Apr 5, 2023

@Cinchoo
i am reading a nacha file for processing and ,i want to get the addendarecord from entrydetail but when I am accessing entrydetail it only shows me addendarecordindicator ,
i am using V 1.0.2.3
can you please guide me or show me some snippet

image

@Cinchoo
Copy link
Owner

Cinchoo commented Jul 9, 2023

he is how you can grab addenda record

        using (ChoNACHAReader fr = new ChoNACHAReader("ACH.txt", new ChoNACHAConfiguration() { FieldValueTrimOption = ChoFieldValueTrimOption.None }))
        {
            foreach (var r in fr)
            {
                switch (r)
                {
                    case ChoNACHAFileHeaderRecord fileHeaderRecord:
                        Console.WriteLine(fileHeaderRecord.ImmediateOrigin);
                        break;
                    case ChoNACHAFileControlRecord fileControlRecord:
                        Console.WriteLine(fileControlRecord.BatchCount);
                        break;
                    case ChoNACHABatchHeaderRecord batchHeaderRecord:
                        Console.WriteLine(batchHeaderRecord.BatchNumber);
                        break;
                    case ChoNACHABatchControlRecord batchControlRecord:
                        Console.WriteLine(batchControlRecord.BatchNumber);
                        break;
                    case ChoNACHAEntryDetailRecord entryDetailRecord:
                        Console.WriteLine(entryDetailRecord.DFIAccountNumber);
                        break;
                    case ChoNACHAAddendaRecord addendaRecord:
                        Console.WriteLine(addendaRecord.PaymentRelatedInformation);
                        break;


                }
            }
        }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants