fixing usage2dia

A few logic changes in HandleString mostly, and fixed the example file