(a) All objections to pleadings shall be raised by motion. The motion shall point out specifically the defects complained of, and shall ask for appropriate relief, such as: that a pleading or portion thereof be stricken because substantially insufficient in law, or that the action be dismissed, or that a pleading be made more definite and certain in a specified particular, or that designated immaterial matter be stricken out, or that necessary parties be added, or that designated misjoined parties be dismissed, and so forth.
(b) If a pleading or a division thereof is objected to by a motion to dismiss or for judgment or to strike out the pleading, because it is substantially insufficient in law, the motion must specify wherein the pleading or division thereof is insufficient.
(c) Upon motions based upon defects in pleadings, substantial defects in prior pleadings may be considered.
(d) After rulings on motions, the court may enter appropriate orders either to permit or require pleading over or amending or to terminate the litigation in whole or in part.
(e) Any party may seasonably move for judgment on the pleadings.
735 ILCS 5/2-615