A bomb blast ripped through a Yugoslav bank office yesterday in a skyscraper on Fifth Avenue, two blocks from where tens of thousands were assembling for the St. Patrick's Day parade. Passerby screamed and scrambled for cover as glass rained from windows of the 30th-floor offices.

There were no injuries, but police said several persons were treated for shock. Office workers were evacuated from the 58-story tower.

The explosion occurred at 10:15 a.m., one hour before first lady Rosalynn Carter was scheduled to meet Mayor Edward I. Koch and other officials for the start of the parade on Fifth Avenue. She had not arrived in New York when the bomb went off.

An anonymous male caller told FBI later that Croatian Freedom Fighters had placed the bomb and directed agents to a Port Authority bus terminal locker where a letter was found. The contents of the letter were not immediately disclosed.

The bomb exploded in a stairwell outside the bank office. Division Fire Chief Elmer Chapman said there was extensive damage to much of the 30th floor and on the 31st floor, mainly through a nearby mail chute.

The blast blew an 18-inch hole in the wall of the stairwell, according to police Lt. Robert Sheehan.

Three persons were in the office of Jugobanka Representatives when the blast occurred. Jugobanka is one of the largest banks in Yugoslavia.