Automatically change the contract

 
I want to program an ea, which automatically changes the contract of the underlying for example Ger30Sep11, Ger30Dec11, Ger30Feb11,....

Is there an possibility to get the actual contract automatically from the MarketWatch. Or how can I program that??

Sometimes, before I can see the new contract, I have to right-click on the MarketWatch and click "all invisible" and after that "all visible" to see it.

Please help, Julia