Take look at convert function in books online.