Usually, you use the accusative case for direct objects and the dative case for indirect objects. However, after a small number of so-called "dative verbs", which include "helfen" (to help) and "danken" (to thank), the dative case is used for the direct object.
See:
http://german.about.com/library/verbs/blverb_dativ.htm