BANGKOK, DEC. 30 -- Vietnam's National Assembly has passed a new foreign investment law geared to attract capital to develop the country's struggling economy, Hanoi radio announced tonight.

The radio report gave no details about the new law, but a draft described to reporters in Hanoi earlier this year suggested that it is one of the more liberal foreign investment laws in the Communist world.

Luu Van Dat, who headed the committee drafting the new code, had told reporters it would allow three main forms of investment: wholly foreign-owned enterprises, joint ventures in which foreigners provide up to 99 percent equity, and contract joint ventures in which the two sides cooperate without forming an enterprise.

Dat, a French-trained economist and lawyer, said foreigners would be allowed to repatriate their profits and would be given guarantees against nationalization.

The new investment law, which has been under discussion for three years, is one of a series of capitalist-style reforms introduced by more pragmatic leaders elected by a Communist Party congress at the end of 1986.

Vice Premier Vo Van Kiet, who gave a downbeat report to the National Assembly last week about Vietnam's economic failures in 1987, said the shortage of capital was one of the biggest problems facing economic development and called on the country's leaders to "draw capital from foreign countries, both socialist and nonsocialist."

The new investment code is also an attempt by Vietnam to break out of its international economic isolation. Most western countries, Japan and Vietnam's noncommunist neighbors cut off aid and credit to Vietnam following its invasion of Cambodia in 1979. The United States has an embargo barring trade with Vietnam.

But businessmen from Japan, Singapore, South Korea, Australia, France, and even the United States are interested and regularly visit Vietnam. One diplomat in Hanoi called Vietnam the "last virgin market" left in Southeast Asia. Companies also are interested in joint ventures to tap Vietnam's cheap, highly disciplined work force.

Observers here doubt the new law will bring a flood of investors. Companies already doing business with Vietnam complain that the country lacks an economic infrastructure. They say its banking system is weak and it has few trained managers or good roads.

Foreign businessmen complain about bureaucracy and say that Vietnamese companies often back out of contracts or fail to meet deadlines. Western investors also are concerned about Vietnam's economic stability. Inflation in recent years has averaged between 700 and 1,000 percent.

Kiet, who is also chairman of the state planning commission, told the National Assembly last week that Vietnam also suffers from sagging production, high unemployment, a rapidly growing population and critical shortages of goods and capital.

The planning chief reported that rice production had stagnated at around 18 million tons for the past three years, causing a drop in per capita consumption because the country's population continued to increase by 2 percent -- about 1 million people -- each year.

"Employment pressure is rising, which causes social instability," Kiet told the National Assembly. Radio Hanoi recently reported that 1 million young people enter the job market each year, but only about 40 percent find jobs.

Kiet indicated the leadership is dedicated to continuing economic reforms even though they have not been a quick cure for Vietnam's economic ills.