Stack Exchange network consists of 178 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
View all activity pages
"Tener puesto" is an expression meaning "to wear", and "puesto" agrees with the thing you have on. Here that's "ropa elegante", something feminine, so I believe you should actually write "Cuando tengo ...