Added ability to read number of available messages