delivered the opinion of the court:
Defendant plead guilty to two counts of aggravated battery and one count of armed violence and was sentenced to 2-6 years’ imprisonment on one count of aggravated battery. Defendant appeals, contending that his guilty plea was involuntary as a result of coercive conduct by the trial • court, that the trial court erred by denying a motion for substitution of judges, that the three offenses arose from the same conduct thus permitting only one conviction, and that the sentence is excessive in the absence of a sentencing hearing.
The record shows that on March 12, 1975, the date on which defendant’s trial was to be held, defendant’s attorney moved for substitution of judge pursuant to section 114 — 5(c) of the Code of Criminal Procedure of 1963 (Ill. Rev. Stat. 1975, ch. 38, par. 114 — 5(c)). The grounds of the motion were as follows: A tentative plea agreement had been reached whereby defendant would plead guilty to the three offenses in return for a recommended sentence of 1% to 5M years, and the terms of the pleá were to be disclosed to the court on the date set for trial. Defense counsel, however, upon arriving at the courtroom that day, learned that the plea had already been disclosed to the judge assigned for trial and was informed by the judge that the plea had been rejected. Defense counsel stated that he felt the judge was prejudiced either against him or defendant due to the manner in which the plea agreement had been disclosed and rejected.
Further discussion between the State’s Attorney, trial judge, and defense counsel revealed that the State’s Attorney had talked with the judge two days previously and had informed him of the terms of the proposed plea. The judge had stated that he would consider the plea and, on the date of the trial, informed both sides that he would not accept it. The judge also afforded defense counsel the opportunity to again present the plea agreement and any evidence which defendant desired the court to receive, but the offer was declined. After further discussion, the motion for substitution was denied.
Defense counsel then moved for a continuance, stating that he had expected the plea to be accepted and was1 unprepared for trial. This motion was denied, and jury selection began. During jury selection, defense counsel conferred with the judge and State’s Attorney, and the conference was moved to chambers. In response to questioning by defense counsel, the judge stated that he had rejected the plea agreement because the recommended sentence was too low. Defense counsel then suggested a plea of guilty in return for a sentence of 2-6 years, which was acceptable to the court and State’s Attorney. Defense counsel consulted with defendant, after which defendant tendered a plea of guilty, was properly admonished by the court in accordance with Supreme Court Rule 402, and the guilty plea was accepted.
The factual basis for the plea showed that during the evening of November 1, 1974, Christopher Smith was in a tavern in Monmouth, Illinois, sitting at the bar. Defendant approached Smith and struck him in the face, breaking Smith’s jaw, and knocking him to the floor. Defendant then stabbed Smith in the leg with a knife.
Defendant first contends that his guilty plea was involuntary because it was coerced by the adverse rulings on his motion for substitution of judge and motion for continuance and by allegedly improper participation by the trial court in the plea negotiations.
The improper participation cited by defendant consists of the manner in which the initial plea agreement was disclosed to and rejected by the court and the subsequent discussion in chambers where a plea agreement was reached.
Supreme Court Rule 402(d)(2) (Ill. Rev. Stat. 1975, ch. 110A, par. 402(d)(2)) provides that the parties may with the court’s permission, disclose a proposed plea agreement to the court and seek the court’s concurrence. It is further provided that the court may receive, with the consent of the defendant, evidence in aggravation and mitigation. We believe that this provision clearly contemplates a procedure whereby both parties participate in open court.
Here, the State’s Attorney had disclosed the plea agreement to the court in defendant’s absence. When the entire record is considered, it is obvious that the State’s Attorney was only attempting to comply with J. Klukos’ order of January 21, 1975, where the attorneys were directed ' 'to intelligently advise this Court before 10:00 a.m. of the date preceding the date set for trial whether or not the respective parties still wish a jury trial 8 8 8.” The record shows that no other information was disclosed other than the terms of the agreement. Moreover, defense counsel, was afforded the opportunity to restate the plea agreement and to present evidence in support of the agreement.
In light of the above facts, we do not believe that the court improperly participated in the negotiation process so as to coerce defendant’s plea. Although the plea agreement should háve been disclosed initially in open court with both parties present, the facts adduced at the hearing show the error to be harmless and further show that the court’s “participation” was no greater than if the plea agreement had been disclosed and rejected in full conformity with Supreme Court Rule 402(d)(2).
Defendant also asserts as improper participation the in-chambers discussion where the judge, in response to questioning, by defense counsel, stated that a sentence of 2-6 years would be acceptable for a plea of guilty. Supreme Court Rule 402 precludes the trial court from initiating plea negotiations and contemplates a limited participation by the trial court in the negotiations. (People v. Fox (3d Dist. 1976), 38 Ill. App. 3d 257, 345 N.E.2d 139; People v. Robinson (1st Dist. 1974), 17 Ill. App. 3d 310, 308 N.E.2d 88.) We believe the judge’s role during the in-chambers discussion was well within the ambit of allowable participation.
In order to prevail on a claim that a trial court participated in plea negotiations so as to render a guilty plea involuntary, defendant must present facts and circumstances which reasonably show that the court, contrary to the provisions of Rule 402, departed from its judicial function and involved itself in the negotiation process to such an extent that improper influence was put on defendant to plead guilty, of that defendant reasonably believes that he no longer can receive a fair and impartial trial and must plead guilty and accept the sentence which has been approved by the court. (See People v. Bannister (1st Dist. 1974), 18 Ill. App. 3d 154, 309 N.E.2d 279.) However, the mere fact that a trial court participates in plea negotiations does not render involuntary a subsequent plea of guilty. (See People v. Rudnicki (1st Dist. 1975), 27 Ill. App. 3d 87, 327 N.E.2d 303.) Here, we do not find that the trial court improperly participated in the negotiations so as to have had a coercive effect on defendant’s decision to plead guilty.
Defendant also contends that his motion for substitution of judge was improperly denied and contributed to the involuntariness of his plea.
Defendant’s motion was made pursuant to the Code of Criminal Procedure, section 114 — 5(c) (Ill. Rev. Stat. 1975, ch. 38, par. 114 — 5(c)), which provides in relevant part:
“ 8 8 8 any defendant may move at any time for substitution of judge for cause, supported by affidavit. Upon the filing of such motion the court shall conduct a hearing and determine the merits of the motion.”
In the instant case, defense counsel was afforded opportunity to make a full oral presentation of the merits of the motion. The court docket reveals that a hearing was held on the oral motion for substitution of judge. “Hearing held — Motion denied.” After a hearing a court’s ruling on such a motion, even if erroneous, is not a jurisdictional defect. (People v. Robinson (1st Dist. 1974), 18 Ill. App. 3d 804, 807, 310 N.E.2d 652.) In this case, since there was a hearing, the proceedings subsequent to the court’s ruling were not void. See Robinson.
The trial court does not have the burden of justifying its retention of the case; the defendant could obtain a substitution of judge only through a showing of actual prejudice. (People v. Haynes (5th Dist. 1974), 21 Ill. App. 3d 1, 2, 313 N.E.2d 601, leave to appeal denied, 57 Ill. 2d 605.) Moreover, the trial court is ordinarily in the best position to determine whether it harbors prejudice against a defendant and is unable to continue in the case in a fair and impartial manner. People v. Polk (1973), 55 Ill. 2d 327, 303 N.E.2d 137; People v. Campbell (5th Dist. 1975), 28 Ill. App. 3d 480, 328 N.E.2d 608.
Here, the allegation of prejudice was based on the manner in which the initial plea agreement was disclosed and rejected by the court. As stated previously, the hearing on the motion showed that no information other than the terms of the plea was disclosed, and defense counsel was given the opportunity to renew the plea offer and present evidence in support of the plea. We do not believe that the record shows the court was prejudiced against defendant or so predisposed as to defendant’s guilt as to be unable to continue to preside fairly and impartially in the case.
Defendant also contends that his motion for a continuance was improperly denied. The granting or denial of a motion for continuance is addressed to the sound discretion of the trial court, subject to review for an abuse of discretion. (People v. Davb (1970), 45 Ill. 2d 514, 261 N.E.2d 314.) The record reveals that on January 21,1975, counsel for defendant was mailed an order by Judge Klukos setting the case for jury trial during March, 1975. Here, defense counsel, on the date set for trial, moved for a continuance on the grounds that he was unprepared for trial due to the court’s rejection of the proposed plea. However, the record shows that defense counsel had been retained by defendant for almost four months, had represented defendant at the preliminary hearing, and had participated in pre-trial discovery. The case was not complex, and, in the absence of a showing of actual prejudice to defendant, we do not believe that the denial of the continuance was an abuse of discretion. See People v. Wibon (1963), 29 Ill. 2d 82, 193 N.E.2d 449, cert, denied, 377 U.S. 955, 12 L. Ed. 2d 499, 84 S. Ct. 1634, rehearing denied, 379 U.S. 873, 13 L. Ed. 2d 81, 85 S. Ct. 22.
Upon review of the record, we believe that defendant’s contention that his plea was coerced must fail. Accordingly, we find that the guilty plea was knowingly and voluntarily entered. See, e.g., People v. Robinson (1st Dist. 1974), 18 Ill. App. 3d 804, 310 N.E.2d 652.
Defendant has also asserted as independent grounds for relief the contention that the court erred in denying his motion for substitution of judge. As noted previously, that assertion has no merit. Furthermore, it has been repeatedly held that a valid plea of guilty waives all nonjurisdictional errors. See Tollett v. Henderson (1973), 411 U.S. 258, 36 L. Ed. 2d 235, 93 S. Ct. 1602; People v. Jones (1st Dist. 1973), 7 Ill. App. 3d 146, 287 N.E.2d 227.
Defendant next contends that all three offenses arose from the same conduct and, therefore, only one conviction is proper. The State concedes, and we agree, that the offense of armed violence is based on the same acts, i.e., stabbing the victim in the leg, as is one count of aggravated battery. Accordingly, the conviction for armed violence, being the lesser offense is reversed.
A more difficult issue exists with respect to the two charges of aggravated battery.
The question of when a defendant’s conduct or a series of closely related acts arising from the “same transaction” properly allows multiple convictions has been a troublesome one for Illinois courts. A purview of relevant cases shows them to be virtually irreconcilable.
We believe that the thrust of the decisions prohibiting multiple convictions arising from the same conduct is to prohibit multiple convictions where the facts show that one offense is based on the same act or acts comprising the other offense (People v. Lilly (1974), 56 Ill. 2d 493, 309 N.E.2d 1; People v. Henderson (3d Dist. 1976), 36 Ill. App. 3d 355, 348 N.E.2d 854), or, in certain instances, where one offense was committed in order to effectuate another offense (see People v. Williams (1975), 60 Ill. 2d 1, 322 N.E.2d 819).
In the instant case, one count charged that defendant committed an aggravated battery by striking the victim with his fist and causing great bodily injury, and the other count charged defendant with committing an aggravated battery by stabbing the victim with a knife. These were separate offenses, committed by separate and distinct acts. One offense was completed before the other was committed and the conduct is clearly divisible. (See People v. Scott (1974), 57 Ill. 2d 353, 312 N.E.2d 596.) Accordingly, we believe that separate convictions were proper on each count of aggravated battery.
Defendant lastly contends that the imposition of a greater than minimum term of imprisonment is excessive in the absence of a presentence report or sentencing hearing.
We believe that the circumstances of the offenses as established by the facts provided an adequate basis for the sentence. (See People v. Dawson (3d Dist. 1975), 33 Ill. App. 3d 768, 338 N.E.2d 425.) The record also shows that defendant, in accordance with the negotiated plea, waived a pre-sentence report and waived a sentencing hearing. Therefore, we believe that defendant’s contention is controlled by People v. Barto (1976), 63 Ill. 2d 17, 344 N.E.2d 433.
Accordingly, the judgments of conviction of the Circuit Court of Warren County are affirmed as to the convictions for aggravated battery and reversed as to the conviction for armed violence.
Affirmed in part; reversed in part.
ALLOY, P. J., and BARRY, J., concur.