DEFINT A-Z infile$ = "h:\playpal\c_tims.csv" 'input CSV file outfile$ = "h:\playpal\c_tims.gg" 'output binary file datstart& = &H96E 'data starts at 0x96E entries = 41 'no. of entries (40 or 41) DIM text AS STRING * 32 DIM byte AS STRING * 1 OPEN infile$ FOR INPUT AS #1 OPEN outfile$ FOR BINARY AS #2 GET #2, datstart&, byte$ FOR xx = 1 TO entries LINE INPUT #1, line$ val.loc = INSTR(line$, ",") - 1 text$ = LEFT$(line$, val.loc) text$ = RTRIM$(text$) + STRING$(32, 0) PUT #2, , text$ val.loc = 0 FOR x = 1 TO 17 val.loc = INSTR(val.loc + 1, line$, ",") val.len = INSTR(val.loc + 1, line$, ",") - val.loc - 1 text$ = MID$(line$, val.loc + 1, val.len) byte$ = CHR$(VAL("&H" + text$)) PUT #2, , byte$ NEXT text$ = RIGHT$(line$, LEN(line$) - val.loc - val.len - 1) byte$ = CHR$(VAL("&H" + text$)) PUT #2, , byte$ NEXT CLOSE