Ok, after seeing this about 20 times today, I'm pretty sure I'm not crazy.
I run a codeunit and notice a problem.
I edit the codeunit. I save it, compile it, etc.
I run the codeunit and see the same problem.
I edit the codeunit and set a breakpoint at/near the place I made the changes (which are visible), and close the editor window. (No change to the code whatsoever.)
I enable the debugger and run the codeunit.
The debugger pops up at the breakpoint and I look around and my code changes are *not there*.
What the ... ?
I exit NAV and restart.
I enable the debugger and run the codeunit.
The debugger pops up on the breakpoint and this time my code change *is there*.
Am I on the wrong meds or something?
Bob
0
Answers
RIS Plus, LLC
Never seen that before. If that's the case though, nothing you can do about it. Close the debugger, close NAV, restart NAV and debug again. It's a pain in the bootie, but if that's how it works that's how it works. Report it to MSFT and hope it'll be addressed in a hotfix.
RIS Plus, LLC
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
I close the debugger between runs.
I learned the hard way what happens if you have extra windows open on C/AL code - you know - losing all your changes when you close the out-of-date window and answer Yes to the save prompt? (Haven't been bitten by this yet? Wait, you will. And you don't forget it!) #-o
So, I'm very consious of what windows are open.
I'll try it a few more times just to be sure before I report it to MS though.
Bob
RIS Plus, LLC
Epimatic Corp.
http://www.epimatic.com
Bob
Epimatic Corp.
http://www.epimatic.com
Changed it to zero. Closed and reopend database.
Confirmed cache is still 0
Ran a given codeunit
Edited codeunit by insering a new code line (not comment)
Closed, compiled and ran the codeunit
Edit the codeunit and set a breakpoint on line above new line
Closed codeunit window
Enabled debugger
Ran codeunit
Debugger comes up at correct breakpoint
New code line inserted previously not visible in debugger.
Conclusion: :bug:
RIS Plus, LLC
It is a single-instance codeunit!
Problem solved!
Thanks to everyone who contributed.
Bob
P.S. Mibuso RULES!
You know the ironic thing is I spent literally days trying to come to terms with the same issue, so I am kicking myself for taking so long to suggest that. ](*,)
RIS Plus, LLC
I had the issue in the very early days trying to add some password enhancements for a client in 1.3, took us a long time to figure it out, so it alwasy ssticks in my head. Recently I was using Ahmeds brilliant little single instance thing to find consistant errors, and had the same issue, and still remembering that earlier instance, I worked it out in minutes instead of days.