More changes to correct integer casting and Format String syntax errors related to move to 64-bit architecture.