The Princess of Wales has said cancer "makes you appreciate all the small things in life" as she met patients and staff at the hospital that treated her.