I rarely ever comment on these cases, especially when they are newer users which may or may not visit the site in the next week, month, or ever again. It's far better off to just do everything yourself. That way, you make sure it actually gets done.
If the user updates that they forgot something, it was a syntax error, or just doesn't provide any answer at all (they just post "solved"), vote to close it as too localized. Oftentimes the question won't get enough attention past that point to be closed by 4 other users, so I usually skip the vote and just flag it for a moderator.
If the user provided a valuable answer either in the comments or edited into their question, then post that as a community wiki answer (so you don't gain reputation off their answer) and then either edit it out of the question or leave the comment (it's one comment, no need to bother moderators with removing it).
You're always welcome to post your own answer, but don't copy what the OP said word-for-word because it is their answer and stealing reputation from an answer you didn't even come up with is frowned upon (the unicorns will come after you).