It's a poor answer, but as everyone admits, the answerer attempted to answer the question:
The OP's edit:
Edit: I didn't read this carefully enough, your code already has it.
OP already has that. Did you even have a look at the code before posting this answer?! Edit - Now that you've realized it, do you mind taking down this answer?
And in the comments above:
It seems like a very bad (perhaps even wrong) answer, that doesn't mean its not an answer though.
That means, however poor that answer is, it is still an answer.
A post is Not an answer when it does not even attempt to address the question. Think:
- An answer that is actually its own stand-alone question
- A comment on another answer
- A post that has nothing to do with anything even remotely related to the current topic, such as, "I like bananas."
There are other posts that aren't really good answers, but are answers:
- Just a link to the documentation, or a blog, or some external resource that addresses the problem
- A literal answer, "Can I do this in Language X?" A: "No".
- A rhetorical answer, "Do you really want to run
GC.Collect() in a loop?
- Addressing the OPs code, "Your code is subject to SQL injection attacks -- here's how to solve that"
- Answers that are entirely wrong, or have technical inaccuracies (we have a declination reason for just this)
In these cases, it is helpful to know exactly what you believe is wrong with the answer, and what you think we as moderators should do about it. I have exactly four options when it comes to addressing a flagged "Not an answer" (or even a
Custom -> Other flag) post:
- Delete the post
- Edit the post
- Leave a comment for the OP
- Do nothing
Your flag should state which action would you like a moderator to take, and why you want them to take it.