If you have issues with your own code, work them out. One thing that helped me deal at my code was to work on my formatting and readability. Breaking up long lines consistent indenting, better variable, field and and function naming etc.
Third, use some concept you 'own' to work on. As in a project of some sort, a concept you understand forwards and backwards... maybe a baseball card database, or an event calendar - maybe you nailed it years ago in language X, do the same now in language Y. This is so you aren't fighting with deciding on what you want, you just need to discover in the language how to get there or how to improve upon what you know, also it will give you a quicker success in the new language which is good for the ego too.
I think also the more experienced (older) we get the more frustrated we get when things just don't just work the first time, so we need to fight that frustration a bit more.