Intellisence errors are due to limitation of VS IDE. Typecasts reversed