What kind of object is the code retrieving? And what kind of object is it trying to cast it to? And what kind of cast is the error message complaining about? Answer these 3 questions, and you should be on your way to solving the problem.
(I am surprised the code even builds. I wouldn't have thought that having multiple UI elements in one layout file with the same ID even works. At the least, it's majorly confusing. But that has nothing to do with the issue at hand - it's an additional problem.)
Ping & DNS - updated with new look and Ping home screen widget
Joined: Mar 22, 2005
On taking a second look - what is the relationship between the code and the layout file? They don't seem to go together.