Samuel Bogley went to Annapolis the other day to meet with the acting governor. For more than two hours, he sat in the elegant office of Blair Lee III, listening more than talking, as the conversation moved from Lee's days as lieutenant governor to the state bureaucracy to education to candor in politics.

When the visit was over, at 6 p.m., Bogley strolled down the State House's inner staircase with a General Assembly roster book in his coat pocket and a renewed assurance that he would know what he was doing when and if the time came for him to work there as the next lieutenant governor of Maryland.

There was only one problem: Bogley could not find his way out of the building.

He roamed the empty first floor corridors for more than 20 minutes, encountering one locked door after another. Finally, he bumped into a woman working late, who found a uniformed guard, who escorted him out through a basement door.

To Samuel Walter Bogley and the people who know him best, the episode came as no surprise. "That's Sam for you," said his father-in-law, Robert J. Brady Sr., who had been waiting nervously back at the family publishing house in Bowie for the arrival of his suddenly famous relative. "Only Sam could get into a situation like that."

Bogley has had an ingenuous, babe-in-the-woods quality about him for most of his 36 years. He somehow managed to retain it through a dozen years in the world of practical politics, eight as a Prince George's County councilman, and now the characteristics of this man are having an impact on the politics of the entire state.

In the four weeks since he emerged from the shadows of local government to become the Democratic nominee for lieutenant governor, Bogley has surpassed gubernatorial candidates Harry R. Hughes and J. Glenn Beall as the most watchable and quotable politician in Maryland.

Reporters who a few months earlier scarcely knew he existed began tracking Bogley's every move, driven by the realization that they had in their midst someone with a penchant for doing and saying unusual, unexpected and agonizingly honest things.

It started on Sept. 13, the day after the primary, when Bogley described in overly modest terms how shocked and flattered he was when former state transportation secretary Harry Hughes asked him to join his statewide ticket. Then followed stories in which Bogley questioned his own grasp of state issues and openly prayed that he would not have to succeed Hughes before he was ready.

From Michael Canning, Hughes' campaign manager, came the word that Bogley should "beef it up a little" and stop belittling himself. The message barely had time to sink in before Bogley was again agonizing in public, this time over the abortion issue.

Bogley and his wife, Rita, oppose all nontherapeutic abortions. Huges supports state funding of abortions for poor women.

On Sept. 29, at a press luncheon in Baltimore County, Hughes said that Bogley would continue Hughes' abortion policy if, for any reason, Bogely had to take over as governor. But Bogley said he was not sure about that, and indicated that he would consider withdrawing from the race if their differences were not resolved.

Hughes and Bogley then locked themselves in a room at their Baltimore campaign office and, five hours later, came out with an agreement that Bogley would not attempt to change Hughes' policy, but also would not fight the General Assembly if it decided on its own to tighten the abortion laws.

But the press kept trailing Bogley looking for more on the abortion flap. Four days later they got it when Bogley said that he still would consider resigning if, on the outside chance that he ever became governor, he had to decide whether to put abortion funds in the budget.

By then, Hughes and his closest advisers had developed a defensive attitude toward Sam Bogley. When Joseph Coole, Hughes' campaign coordinator, was asked about Bogley's most recent comments, he began muttering in Spanish, then recited a Robert Frost poem.

Although Bogley's statements and appearance have been carefully monitored by his friends, relatives and aides in recent weeks, the tall, soft-voiced candidate said he will continue to speak out on moral and social issues. In a recent interview in Bowie, for example, Bogley said he was disturbed by a recent trend in the women's movement to set up homes for battered wives.

"I think it's wrong to say to a woman that it's all right to just run away from the problems at home," he said. "We have to do everything we can to keep families together, not encourage more of them to split up. There was one time when my wife left me and went home to her mother, who told her: 'Rita, your place is with Sam.'"

Democratic politicians have mixed opinions on whether Bogley has helped or hurt Hughes. Those who consider him a minue have generally refrained from saying so publicly, but grimace or roll their eyes toward the ceiling when they hear his name.

His supporters portray him as part boy scout, part saint, and argue that his candor and modesty are precisely what the sinister Maryland political world most needs.

Bogley's public record, however, shows him to be neither an embarrassment nor a saint, but rather an average, conventional and somewhat conservative man.

The political life of Sam Bogley began 12 years ago when his father, an Old Guard Democrat in Prince George's, helped get him a patronage job as chief administrative clerk to People's Court Judge William H. McGrath. The judge was sometimes a vinegarish country jurist who was fond of telling defendants: "Son, next time bring a toothbrush with you."

When Bogley was asked recently what he learned from McGrath, he replied: "I learned to say 'How high?' when the judge asked me to jump." Bogley has never lost that respect for those he has considered his superiors, even though he has often been portrayed as a free-thinking maverick who could not be controlled by the Democratic leaders of his county.

In 1970, Bogley was approached by Fred L. Wineland, the conservative state senator from southern Prince George's, and asked to run for the County Council.

Bogley said he was recruited for two reasons: the Democratic ticket needed a conservative, pro-business representative and his name was the same as his better-known father's.

Bogley did mostly what was expected of him during those first four years in county government, articulating the business point of view on a generally prolabor council. He was chosen as the council's social services watchdog, he said, "because everyone knew I wouldn't give the store away."

As he became more involved in the government, however, Bogley's conservative, probusiness attitudes began to soften. By the beginning of his second term when the council as a whole was more conservative, Bogley had developed a reputation as the council's spokesman for the powerless an disadvantaged.

He had also developed a reputation as a maverick on the council, the one politician who refused to take part in the vote-trading that is an everyday part of life in Upper Marlboro.

Bogley said he consciously became more and more independent because "there were no Republicans on the council and it needed someone who would fill that void," not because he disagreed with most of what the council was doing.

Although Bogley made few enemies on the council, he did antagonize many of the leaders in his hometown, Bowie, by opposing a hospital project for the community and voting against what he considered the parochial interests of that town on several sewer and zoning issues.

"Sam Bogley happened to be in the right place at the right time," said State Sen. Thomas V. (Mike) Miller. "It's an open question whether he'll survive on Annapolis."

Bogley said in a recent interview that he is more concerned about Hughes' survival than his own. "I don't have the ambition to be governor and I don't think I'd ever get elected on my own, anyway," he said. "I don't have the instincts for it, and my abortion position would kill me."