FORT LAUDERDALE, Fla. (AP) _ The former president of ESM Government Securities Inc. struggled to keep the firm open when it was failing because he made so much money from it, prosecutors charged in the federal fraud trial of two former company executives.

The securities company's collapse in March 1985 left 69 investors, including several municipalities, with $315 million in losses and led to a crisis among Ohio savings and loan organizations.

Nicholas B. Wallace, former ESM president, and Stanley Wolfe, who controlled the wiring of ESM funds and monitored securities pledged to secure loans, went on trial Monday before U.S. District Court Judge Jose A. Gonzalez Jr.

A 44-count federal wire and mail fraud indictment charges that they were co-conspirators in a scheme to conceal and falsely report ESM's financial condition through false and fraudulent journal entries and financial statements.

Just days before Fort Lauderdale-based ESM was closed, Wallace told a friend he wanted the company kept open, Assistant U.S. Attorney Jane Moscowitz said.

''When ESM stood on the brink of disaster, Wallace said, 'We've got to find a way to keep ESM open. It's the greatest money-maker ever,''' Ms. Moscowitz told jurors.

Wallace received $2.3 million in salary and bonuses over five years and obtained $4 million in personal loans from the firm, she said.

Government witness Nancy Coleman, once an ESM worker, testified that Wallace falsely promised investors that their securities were segregated at a New York bank.

But defense attorneys said their clients knew nothing about the frauds they admitted were committed by the securities firm.

''Mr. Wolfe and council do not quarrel that a massive fraud was perpetrated on the American public,'' said Paul Lazarus, Wolfe's attorney. ''What our contention is is that Wolfe didn't know about this scheme. ...

''(Wolfe) was an officer with basically no authority. This scheme was hatched by a very smart and very evil man,'' Lazarus said, referring to ESM's late chief financial officer, Alan Novick. ''You will see Mr. Novick gave authority to no one else.''

''No one treated Nick Wallace as a president. Everybody knows that Nicholas Wallace was president in name only,'' said Al Thomas, one of Wallace's attorneys.

The defense attorneys told the jury the fraud was masterminded by Novick and the chairman of ESM's board, Ronnie R. Ewton.

Lazarus said those working at ESM relied on an audit done by Jose L. Gomez of the Alexander Grant and Co., which showed the company was solvent.

He said Novick, who died of a heart attack in his office in November 1984, and Ewton bribed Gomez into producing a financial statement which showed the company making a profit when in fact the company was going broke.

''Up until the day (Novick) died, he represented to the company that the investments were super and that they represented millions and millions of dollars,'' said Thomas.

But Assistant U.S. Attorney Jane Moscowitz said the defendants knew all about the scheme and hid the company's losses by transferring them from ESM Government Securities to the parent company, ESM Group.

Seven others named in the indictment pleaded guilty earlier this year.

Wallace faces 41 counts of mail and wire fraud. If found guilty on all counts, he could get up to 205 years in prison and $50,000 fine. Wolfe is charged with 26 counts, and faces a maximum of 130 years in prison and $35,000 in fines if convicted on all 26 counts.

In a separate case, Wallace pleaded guilty Feb. 4 to forgery charges for witnessing a forged will attributed to Novick. He also pleaded guilty to a related perjury charge.