Robert Downey Jr. has had a long history with Disney, including some less than redeeming moments.

RELATED: Tom Holland And Robert Downey Jr. Reunite Amid Sony-Disney ‘Spider-Man’ Dispute

Speaking on stage at the D23 expo’s Disney Legends Ceremony, the “Iron Man” actor revealed that he was once arrested at Disneyland, Entertainment Weekly reported.

“Here’s a bit of trivia for you. The very first time I went to Disneyland I was transported to another place — within moments of being arrested,” he said. “I was brought to a surprisingly friendly processing centre, given a strict warning, and returned to, if memory serves, one very disappointed group chaperone. I’ve been sitting on that shame for a while and I‘m just going to release it here tonight.”

Downey Jr. continued, “I would like to make amends to whoever had to detain me for smoking pot in a gondola without a license. And I don’t wanna further confuse the issue by insinuating that pot smoking licenses for the gondola are in any way obtainable.”

RELATED: Robert Downey Jr. On Life After Iron Man: ‘I’m Not My Work’

After the anecdote, Downey Jr. got a bit more serious talking about working on the Marvel franchise.

“I’m delighted to be among such a rich and diverse group of humans, all seeking to reflect the many challenges of life through the lens of creative expression,” the actor said. “For my part, playing Tony over many years, the thematic idea that technology can guide our species towards enlightenment or destruction, it’s been a really worthwhile and ongoing meditation. Honestly, it’s been a great gift.”

Downey Jr. made his first film with Disney, “The Shaggy Dog”, in 2006, followed by “Iron Man” in 2008. He went on to play the superhero throughout the Marvel Cinematic Universe, until exiting the franchise with “Avengers: Endgame” earlier this year.