Use a div when there is no other suitable container for the content you are presenting. Most times there will be something more suitable (e.g. headings, p elements, lists, dl, tables etc).
Divs are mostly used to group elements together and provide a logical structure but if the content you are presenting has no semantic html element than you can use a div for block level content and a span for inline level content.
Some people use divs to wrap images but I think that if an image has been placed in the page because it is important to content (otherwise it would have been a background image) then it should be in a p element because it is saying something (others may disagree but that's their choice as these things are not set in stone).