Even if you set MAX_ACCOUNTS to be 5, your do while loop still checks that counter is less than the integer 10 rather than MAX_ACCOUNTS, assuming that 1 is continually entered after counter surpasses MAX_ACCOUNTS.

You'd be pretty much trying to use an object that you never created, is what I think the problem is.

Oh, I'm actually saying you should check it to that. You've specified that MAX_ACCOUNTS is the amount you'd like the user to have, but elsewhere you've used a constant value i.e. 10 rather than the variable MAX_ACCOUNTS.

Your counter variable should be comparing itself to the amount you specified when you declared your array of objects. Still, you'd have a problem if the user exits before each object is given values. If you're specifying the amount of objects you'd want the user to utilize, then you could always remove the input test and have them read in data for MAX_ACCOUNTS amount of objects.

Thank you to both of you it works now. I don't get how a few lines of code that seemingly says the same thing can alter everything and get you to the results you want...Not sure I will ever be able to understand C++.