Bad, bad, bad idea for many reasons.
1. He probably can't do it, unless he has left his employer. Possibly you could borrow against it, but it is still a bad idea.
2. You will pay penalties.
3. You will pay more in taxes.
4. You say you have been losing money in his account. Right now those losses are only "paper" losses. If you cash out, those losses become real and you will have done the worst thing in investing -- bought high and sold low. You don't say what your 401k is invested in, but if it is in a solid portfolio (index funds, etc.), then you just need to ride with the market and not look at your balance for awhile. The whole market is getting battered around a bit now, but that means it's time to be buying stocks/mutual funds/ETFs, not selling them. If, however, you have all of your eggs in the one basket of just your company stock or some other investment you have no confidence in, you should look at diversifying your portfolio. Whether you need to suck it up and take a loss on what you have already bought (if you think the company is headed to bankruptcy) and reinvest it elsewhere, or merely should divert future contributions into a more diversified portfolio is something you should talk over with a Certified Financial Planner.
But all in all, using retirement funds to pay off a HELOC is not a good idea. You are turning potential loss into actual loss, then paying off taxes, then paying penalties on top of that. You'll be getting cents on the dollar, plus undercutting the future earnings of your investments.