Fixed print file problem