One of the Bible's most comforting truths is that we can know beyond a shadow of doubt that we will go to heaven when we die. The Bible's promise is meant for every believer: "We have this hope as an anchor for the soul, firm and secure" (Hebrews 6:19).
Unfortunately, however, many people are like your friend. They may have professed their faith in Christ; they have been active in their church; they may truly believe the facts of the Gospel. But they have failed to understand one crucial truth, and it is this: Our salvation does not depend on how good we are, but solely on Christ and what He has done for us.
In God's eyes, we are all guilty, because we all have sinned and broken His laws. But we can't erase our own guilt–nor can we win God's favor by balancing out our bad deeds with our good deeds. The reason is because God is absolutely pure and holy, and even one sin is enough to keep us out of heaven.
But that is why Christ came into the world. He came for one reason: to take away our sins by His death on the cross. We deserve to die for our sins, but He died in our place. He paid the price for our sins–not part of them, but all of them! This is why the Bible says, "He who has the Son has life" (1 John 5:12). Trust Christ alone for your salvation–and urge your friend to do so, as well.