
759 S.W.2d 201 (1988)
Javier DE LEON and Luis Cruz, Relators,
v.
Honorable Mickey PENNINGTON, Judge of the 38th District Court of Texas, Respondent.
No. 04-88-00470-CV.
Court of Appeals of Texas, San Antonio.
October 26, 1988.
Hector Leal, Jr., Leal & Bratt, Laredo, for relators.
Rogelio Munoz, Dist. Atty., Uvalde, for respondent.
Before CADENA, C.J., and CANTU and REEVES, JJ.


*202 OPINION
PER CURIAM.
This is an original mandamus proceeding. Relators were arrested in Medina County, and were charged with the felony offense of illegal investment under the Controlled Substances Act. TEX.REV.CIV.STAT. ANN. art. 4476-15 § 4.052 (Vernon Supp. 1988). They each deposited $2,500.00 in cash as bail to secure their appearance at all court hearings thereafter. The money was transferred to the Medina County District Clerk who is custodian of the funds of the 38th District Court in which relators were tried.
Relators complied with the conditions of their bonds, and on June 27, 1988, they appeared for trial and pleaded guilty to the offenses charged. They were each fined $5,000.00, were ordered to pay court costs and were ordered confined in the Texas Department of Corrections for five years. Imposition of the sentences was suspended, and defendants were placed on probation for five years. No motions for new trial or notices of appeal were filed.
Relators filed a written motion for release of the bond money which was denied by respondent in an order signed August 30, 1988. The order concludes, "the bond monies ... are hereby forfeited and applied to the fine assessed such Defendants in this cause." Relators filed this writ of mandamus asking us to order respondent to release their bond money.
In cases in which the court of appeals is called upon to issue a writ of mandamus in a criminal matter, the relator must meet a two-pronged test. He must show that he has no other adequate remedy at law and that the act he demands the trial court to perform is a ministerial act rather than discretionary. Dickens v. Court of Appeals for the Second Supreme Judicial District of Texas, 727 S.W.2d 542, 549 (Tex.Crim.App.1987); State ex rel. Millsap v. Lozano, 692 S.W.2d 470, 481 (Tex.Crim. App.1985).
Relators have no other adequate remedy at law to obtain the release of their funds. The order denying their motion and "forfeiting" their funds is not a proper judgment nisi. Such a judgment can be entered only if the defendant fails to appear in the court where his case is pending. TEX.CODE CRIM.PROC.ANN. arts. 22.01 (Vernon Supp.1988), 22.02 (Vernon 1966). It is undisputed that defendants made all required appearances. Therefore a judgment of forfeiture would have been improper. Counsel for respondent admitted at oral submission that it was for this reason that the State did not pursue forfeiture. Even if the court's order could properly be termed a judgment nisi, such orders are interlocutory and not appealable. Hokr v. State, 545 S.W.2d 463, 465 (Tex.Crim.App. 1977). The order complained of is not one that can be appealed.
We also conclude that the court's duty to refund the cash deposits is a ministerial one. The prime object of bail is to secure the presence of the accused at trial. McConathy v. State, 528 S.W.2d 594, 597 (Tex.Crim.App.1975). It is not a revenue measure intended to be a substitution for a fine or to turn the securities of the alleged offender into a penalty. Id. TEX.CODE CRIM.PROC.ANN. art. 17.02 (Vernon 1977) states that any cash funds deposited under that article in lieu of a surety bond "shall be refunded to the defendant if and when the defendant complies with the conditions of his bond, and upon order of the court." The bond cannot be forfeited for violation of the probationary condition to pay a fine. McConathy, 528 S.W.2d at 598; Trammel v. State, 529 S.W.2d 528, 530 (Tex.Crim.App.1975). Thus, the trial court had the ministerial duties to grant relators' motion to return the bond money and to order the custodian of the bond money to release those funds. He must also vacate his order of August 30, 1988, in which he denied relators' motion and "forfeited" their funds.
The writ of mandamus is conditionally granted. We assume that respondent will enter an order in compliance with this opinion. The writ of mandamus will issue only if he fails to do so.
