Added doMessage

Added doMessage and fixed command cases.