Amber Hunt, Associated Press
The hearse of former Gov. Bill Janklow arrives at the Capitol building in Pierre, S.D., Monday, Jan. 16, 2012. The body will lie in state from 7-11 a.m. Tuesday in the Capitol Rotunda before returning to Sioux Falls, S.D., for a Wednesday funeral.

PIERRE, S.D. — Hundreds of people, ranging from family friends to political foes, gathered Tuesday to honor former Gov. Bill Janklow, who they said left his imprint on nearly every aspect of South Dakota life for four decades.

Janklow, who served four terms as governor but resigned as South Dakota's lone congressman after causing a fatal traffic accident, died Thursday of cancer at age 72. His funeral will be held Wednesday in Sioux Falls.

Tuesday began in Pierre with Janklow's coffin lying in state in the Capitol Rotunda. Visitors somberly filed past the flag-draped casket, some wiping away tears as they remembered a man who was controversial but largely respected.

Later, after a motorcade escorted Janklow's hearse the 230 miles from Pierre to Sioux Falls, the tone turned more celebratory as about 700 people crowded a church and shared stories of a man who loved his family and adored '50s music so much that he requested it be played at his wake.

Friends described the former governor as brilliant and hard-charging, and said he changed South Dakota's economy, schools and even its railroad system.

"Again and again, decade after decade, Bill Janklow proved there was nothing too arduous, nothing too ambitious, nothing too audacious for South Dakota to achieve," Gov. Dennis Daugaard said.

South Dakota Supreme Court Justice Steven Zinter, a long-time friend of the late governor, said Janklow was passionate about getting things done but also took time to help those in trouble.

"He had compassion for the poor, the disadvantaged, those in need and the oppressed," Zinter said.

Former Democratic lawmaker Lars Herseth, of Houghton, said Janklow was sometimes his political ally, sometimes his foe, but always his friend. He said it's hard to envision South Dakota without the changes Janklow made, such as wiring schools for the Internet.

Some mourners showed up before dawn to file past Janklow's coffin in the rotunda. Many bowed their heads for a moment as they passed, just a just a few feet from the office Janklow occupied for 16 years. A pianist played a variety of tunes, including the Beatles' "Yesterday."

Judy Fott, 68, drove 100 miles with her 70-year-old husband, Joe, from their home in Hamill to get to Pierre before 7 a.m. They met Janklow when they had hunters on their land for the annual pheasant hunt hosted by the governor.

"If you were walking down the street, he'd call you by name," Judy Fott said. "We are not special people. We are farmers, but we were friends with him."

Janklow's coffin had been brought into the Capitol on Monday night, when about 100 of his closest friends gathered to pay their respects.

On Tuesday, two state troopers and two South Dakota National Guard officers stood as honor guards near the coffin. A red U.S. Marine Corps flag and a Chicago Bears banner hung from balconies overlooking the rotunda, signifying Janklow's military service and his devotion to the football team.

After the later ceremony, bagpipes played as Janklow's coffin was carried down the front steps of the Capitol to a motorcade. Highway Patrol troopers gave Janklow a 21-gun salute, followed by the playing of taps. Two military jets roared overhead in his honor.

About four hours later, hundreds more people crowded Our Savior's Lutheran Church, where the somber was tinged with celebration. Janklow's family had invited Arlie's All Stars to play the late governor's favorite '50s tunes.

"It's the greatest sad honor the band's ever had," said band leader Arlie Brende, who met Janklow in 1972 when Brende was a legal intern for then-Gov. Dick Kneip.

Tuesday's daylong events drew not only Janklow's famous friends, but also those who knew him in less public ways.

Randy Baloun, 58, and his wife, LeAnn, 56, traveled 50 miles early Tuesday to pay their respects to Janklow, who did legal work for their farm and ranch near Highmore. They knew him for just two years.

"He was just a marvelous man," Randy Baloun said. "We came here to say our last goodbye to him."

Carrie Mikkonen, 63, of Pierre, cried quietly as she walked past Janklow's coffin, noting that her husband died more than a decade ago of the same kind of brain cancer that struck Janklow.

Mikkonen said she was not surprised that Janklow underwent experimental treatments in the past two months. "It's typical Janklow — going to fight to the end," she said.

Former state lawmaker Steve Cutler, 63, also cried as he remembered Janklow — not only as a forceful governor but also as a compassionate man who quietly helped people who had financial problems or other trouble. He said Janklow once bought a power lift so a woman could care for her disabled husband at home.

"I came because I loved him. He did so many great things people never knew about," said Cutler, who worked with Janklow when Cutler was in the South Dakota House from 1985 to 2000.

As Gov. Dennis Daugaard watched people file though the Capitol early Tuesday, he said Janklow did things decades ago that are still having an impact on South Dakota. For example, Janklow saved rail service and attracted credit-card banks to the state in the early 1980s.

The current governor said Janklow taught him to do what he thinks is right without worrying about what others would think. And, Janklow challenged the belief among some residents that a small state can't accomplish much, he said.

"I think one thing South Dakota will always remember about Bill Janklow is how he helped us believe in ourselves," Daugaard said.

Associated Press writers Kristi Eaton and Veronica Zaragovia contributed to this report from Pierre; Dirk Lammers contributed from Sioux Falls.