I am using dosBox and nasm to run this program. I am trying to write an assembly program that takes a user inputted string, then takes each character from that string and puts it into a register. I thought doing mov byte al, msg2 would do the trick. However, I receive an error, obj output driver does not support one-byte relocations". How do I take one character at a time from a string and store it into a register?
%include "io.mac"
.STACK 100H
.DATA
msg1 db "Please enter your name",0
msg2 TIMES 10 Db 0
.CODE
.STARTUP
PutStr msg1 ; print msg1 on the output
nwln
GetStr msg2 ; input string into first space in table
nwln
PutStr msg2 ; output string in register table
mov byte al, msg2
PutStr ax
done:
.EXIT