"After Moses and Aaron left Pharaoh, Moses cried out to the Lord about the frogs he had brought on Pharaoh. And the Lord did what Moses asked. The frogs died in the houses, in the courtyards and in the fields. They were piled into heaps, and the land reeked of them. But when Pharaoh saw that there was relief, he hardened his heart and would not listen to Moses and Aaron, just as the Lord had said." NIV translation
What appeared to be unconditional surrender to the will of God turned out to be just a desire to escape a current problem. When the problem was removed, the true state of Pharaoh's heart was revealed.
The same type of thing happens with us in our Christian walk as we can see people make a profession of faith when times are tough but, when the tough times pass, so does the faith. Many people have seen this happen and concluded that the people had lost their salvation. The opposite has happened in that those people are like Pharaoh. They never surrendered to the will of God and did not lose their salvation but did not have it to begin with.
"Then the Lord said to Moses, 'Tell Aaron, "Stretch out your staff and strike the dust of the ground," and throughout the land of Egypt the dust will become gnats.' They did this, and when Aaron stretched out his hand with the staff and struck the dust of the ground, gnats came on people and animals. All the dust throughout the land of Egypt became gnats." NIV translation
The pattern of warning is changed now as Moses and Aaron immediately executed the next plague. The gnats were probably lice or ticks and was a direct attack on their earth "god" Geb. This reminds us that there is a point where God will stop warning us of our need to repent and He will initiate judgment.
"But when the magicians tried to produce gnats by their secret arts, they could not. Since the gnats were on people and animals everywhere, the magicians said to Pharaoh, 'This is the finger of God.' But Pharaoh's heart was hard and he would not listen, just as the Lord had said." NIV translation
When the magicians could not duplicate the plague, they informed Pharaoh that it was the hand of God. Even with the testimony of his prized magicians, Pharaoh still rejected the will of God.
This reminds us that our surrender to Jesus as Savior and Lord is not based on what someone else says but on what is at work in our hearts.