Problems with a/syncExec methods

Hi,

My application is based in a graphic interface which are painting differentes objects of canvas type. In parallel, runs differents Threads that modify the state of this objects. The problem is redraw method calling generate it a Exception that it say: “Invalid thread access”

I implement code to asyncExec and syncExec method but redraw method failed (“NullPointerException”).

Somebody knows why?

Thanks.