Treatment for depression and telling work

Has anyone taken time off of work to go through a depression treatment program (like an IOP)?  If yes, did you tell your boss that it was depression or something else?
I'm just not sure I want my boss to know about my problems with depression.