One element of spiritual maturity is realizing the horror of sin. It brings great tragedy. Bishop William Culbertson used to speak of the tragic consequences of forgiven sin. For example, David was forgiven, but his baby died, and Absalom and Amnon were slain. God will forgive our sins. In His grace He forgives; in His government we face the consequences. God requires that we reap what we sow.
Temptation is not sin, but it is a sin to cultivate temptation and yield to it. Sin is usually a process, and David went through several stages that led to his sin.
First, David laid down his armor (II Sam. 11). Do you put on the spiritual armor? (Eph. 6). We put it on through prayer. We need to come to the Lord each morning and put on the armor. Second, David was not looking to God. He was looking at Bathsheba. We need to make sure our bodies belong to God. After you put on your armor, turn yourself completely over to Him (Rom. 12:1). Third, David did not watch and pray. The flesh is weak. As we mature in the Christian life, sin becomes more subtle. We must guard against this. Fourth, David was alone. He was not fellowshipping with the saints. When people try to rely solely on themselves, they usually fail. Fifth, David ignored God's Word. The Word keeps us clean. Finally, David did not depend upon the Spirit. We need to yield to Him. If you do, you will conquer sin.
Commit these six stages to memory and read Ephesians 6. Don't make the same mistakes David made. Never cultivate a temptation with a view to yielding to sin. Meditate on the Word of God, obey it and guard your heart with its truth. Stay in fellowship with the Lord.