This stuff is getting terribly unwieldy ; seems like time for a sscanf or similar