Any party to a civil action or defendant in a criminal action, at the opening of trial and before the empaneling of the jury is commenced, by motion to quash the jury array, may challenge the jury panel on the ground that the members thereof were not selected substantially in accordance with law. If the motion is sustained, then the trial will be stayed until a jury panel has been selected and qualified in accordance with law. Such a challenge is waived if not raised before the trial jury panel has been sworn and selection of the trial jury commenced.
NMS § 38-5-16