I have experienced similar problems due to the type casting back to your class not resulting in the correct vtable. The class I passed had multiple inheritence. In order to fix the problem, I first had to cast the LPVOID to the base class, and then once again cast that resulting pointer into the desired class. Anyhow, that is what worked for me.
P
Patrick_Kutch
@Patrick_Kutch