"So the LORD said to Joshua: 'Get up! Why do you lie thus on your face? Israel has sinned, and they have also transgressed My covenant which I commanded them. For they have even taken some of the accursed things, and have both stolen and deceived; and they have also put it among their own stuff. Therefore the children of Israel could not stand before their enemies but turned their backs before their enemies, because they have become doomed to destruction. Neither will I be with you anymore, unless you destroy the accursed from among you. Get up, sanctify the people, and say, 'Sanctify yourselves for tomorrow, because thus says the LORD God of Israel: 'There is an accursed thing in your midst, O Israel; you cannot stand before your enemies until you take away the accursed thing from among you. In the morning therefore you shall be brought according to your tribes. And it shall be that the tribe which the LORD takes shall come according to families and the family which the LORD takes shall come by households; and the household which the LORD takes shall come man by man. Then it shall be that he who is taken with the accursed thing shall be burned with fire, he and all that he has, because he has transgressed the covenant of the LORD, and because he has done a disgraceful thing in Israel'" (Josh. 7:10-15).
God mildly rebukes Joshua by telling him to get up and get busy! There was work to do, and prayer alone wasn't going to solve this problem. The nation had sinned by disobeying God's explicit instructions. They were guilty of stealing and deception. They needed to address their transgression properly if they wanted God to be with them in battle again and enjoy success. There was no other way for them to be restored to the LORD. Even today friends, when we do evil, God will not be with us. As Peter wrote - "The eyes of the LORD are on the righteous, and His ears are open to their prayers; but the face of the LORD is against those who do evil" (I Pet. 3:12). Prayer is powerful, but it does not replace repentance!
Every time I read Joshua 7, I am struck at the impact one man's sin can have. In a nation of a couple million people, one man's sin led to military defeat, widespread doubt, and unnecessary death (for several dozen innocent men). Even today one man's sin can cause tremendous heartache and pain for many. The Israelite nation as a whole had entered into a covenant with God, but they had not kept it because of one man's covetousness. God had not failed them; they had sinned! God would assist them in solving this problem, however. He would help Joshua identify the guilty party the next day. In the meantime, Joshua was to exhort the nation to sanctify itself. Once the guilty party was identified, he would have to be executed if the nation wanted to be restored to God's favor.