Trivia: The Federation flag has the Roman numeral MMCLXI, which is 2161, the year that the United Federation of Planets was founded. It's motto, "Ex axtris scientia" is latin for "from the stars, knowledge."
Trivia: Because of guest star Leonard Nimoy's schedule, this episode was filmed before part one.
Trivia: The actor that plays young Batai, son of Kamin/Picard, is played by Daniel Stewart, the real life son of Patrick Stewart.
Answer: Yes. The doors to the holodecks can be locked when in use by anyone aboard the Enterprise so they couldn't be disturbed. However, high ranking officers like Captain Picard could override the doors as it's seen that overrides are in use even for the crews quarters. Even Barclay, when he's indulging in one of his fantasies could have the doors to the holodeck unlocked by an override code.