Why then have you despised the word of Yahweh by doing what is evil in my eyes? You struck down Uriah the Hittite with the sword and took his wife as your own wife — you killed him with the sword of the Ammonites.
In context
7Nathan said to David, “You are the man! This is what Yahweh, God of Israel, says: I anointed you king over Israel, and I delivered you from the hand of Saul. 8I gave you your master’s house and your master’s wives into your arms, and I gave you the house of Israel and Judah. And if that had been too little, I would have given you even more. 9Why then have you despised the word of Yahweh by doing what is evil in my eyes? You struck down Uriah the Hittite with the sword and took his wife as your own wife — you killed him with the sword of the Ammonites. 10So now the sword will never leave your house, because you despised me and took the wife of Uriah the Hittite to be your own wife. 11This is what Yahweh says: I am going to bring disaster on you from within your own house. I will take your wives before your very eyes and give them to another man, and he will sleep with your wives in broad daylight.