You have to find out what you are looking for when you seek out the affair. It is having some benefit to you and that is the key to why you look elsewhere. Is it attention. Is it something that is lacking in your marriage. You have to figure that out. It may even be some sort of validation. There is something lacking that you doing this and there is a payoff to it. What is that. Is it a way to divert away from your grief. You are willing to risk everything so it has to be something major. That is where the key lies. Marriage counseling can't help you decide what you are looking for. I would pursue an individual counselor. Find out why you are doing this in order to stop it. It may just be a dysfunctional way to dealing with a void. Your marriage certainly is in danger. Because now you have to tell him about this. Their may be some sympathy to forgive you if you seek help. Grief can take many forms. So does a marriage when there is something missing. Find a way to get past this.
Sorry for the delay. If this was helpful press accept