CU 80 For test

Hello I search to do a CU 80 who do just test and not insert an not modify the records. And then report the errors before starting the CU80. Can anybody help me ? Can i use existing report or CU ? Or has anybody a CU who work like that. Sorry for my englich. Didier

Sorry, I can’t understand what you are trying to say. Perhaps you could ask in French and someone else could translate? Bill Benefiel Manager of Information Systems Overhead Door Company billb@ohdindy.com (317) 842-7444 ext 117

I’m not quite sure of what you’re looking for here but I’ll attempt a couple of suggestions. If you want to make sure there are no errors that standard Navision code would identify, you don’t need to worry because when an error is identified, the entire thread is aborted and Versioning takes care of resetting the database back to pre-post status (actually your updated copy is discarded). If you want a special routine to test with, that does the processing but then no updating, you can just put an ERROR statement just in front of the CU 80 EXIT or in the calling code right after the call of CU 80. Dave Studebaker das@libertyforever.com Liberty Grove Software A Navision Services Partner

I write this code : IF ComptaVente.RUN(“En-tête vente”) THEN BEGIN //MESSAGE(’%1’,“En-tête vente”.“Type document”); IF “Reste à livrer” THEN BEGIN IF “En-tête vente”.FIND THEN BEGIN CLEAR(Reliquat); EnteteVente2:=“En-tête vente”; Reliquat.InitSoucheBordereau(); Reliquat.RUN(EnteteVente2); EnteteVente2.COPYFILTERS(“En-tête vente”); END; comptavente is the variable from the CU 80 I use the If comptavente.RUN (…) to test the good end. But with this test : if comptavente.run(… i haven’t the display from the ERROR in th CU 80.

Hi Didier, i wish that my french was as good as your english. Maybe Report 202 can help you out. This report sums up all the errors of your SalesHeader and SalesLines. Regards, Reijer.

I understood clearly what you wanted :slight_smile: but just to make sure: You are running a routine where you want to identify ALL the possible errors BEFORE you start posting the Sales Order. This is common in automated processes, for example, you may be importing data from another system and it is critical that the invoice posts, you can’t have any error stopping the whole process. If that is correct then… The first step is to start with a copy of CU80, and the code from the Invoice Test Post Report R202 as mentioned by Reijer). You end up with to problems that you need to work on:- The first is that it is not only CU80 that generates the errors, so you need to follow all the other codeunits (12, 22 etc) and worse, all the validations on fields in tables.

  • The second in how to report the errors back to your “batch” routine.
    My suggestion, is that instead of starting this way, do it this way: Create a temporary invoice posting buffer, basically two tables which are stripped down copies of tables 36 and 37. Since you are doing this for a specific customer, they will not need to allow for every exception that CU80 allows for. So you can write a much simpler routine. For example, if you are not selling resources, just don’t allow resource lines. Then all you need to do is, IFF all the fields are OK, then copy to an actual order, and post. Then the onese that had errors stay in the buffer, and the user can go back and manually fix them. I hope this helps. AND AN IMPORTANT NOTE: English is my native language, I also speak a few others (well sort of), and I never worry about people laughing at me in those languages. I even got reprimanded once for writting a letter in English English and not in American English once, (I still laugh at that). This is an international forum, and we are very tolerant, and I wish to thank you for making an effort to speak in my language. I humbly appologize/appologise that my French does not come even close to your English. _________________________ David Singleton Navision Consultant since 1991 dmks22@home.com___________