It's not up to the judge its up to the DA. If they have participating witnesses they are unlikely to dismiss the case.
Macy Jaggers's answer to a legal question on Avvo does not establish an attorney-client relationship. Please consult an attorney who practices criminal law in your jurisdiction for the most accurate legal advice.
Judges generally are not the ones who dismiss criminal charges. Charges that are dismissed prior to trial would be based on a motion filed by the district attorney's office. These are filed for several different reasons, that are often case specific, such as if the Defense wins a motion to suppress, or if the defendant completed some sort of diversion program or completed the terms of a conditional dismissal agreement.
It is up to the D.A. to drop the charges by filing a motion to dismiss. There are several reasons why they would do this, including if proof was submitted that your friend could not have committed the crime.
Ramiro Estrada's answer to a question on Avvo does not create an attorney-client relationship. Furthermore, the answer is a general response to a general question, and is not given as advice and therefore no action should be taken in reliance of said answer.