People, pls. help to code something like that Readln in Pascal for reading lines from File/Console. :) Igor Soumenkov
Posted on 2001-01-01 14:47:00 by isumenko
in the masm32 library there is a function called StdIn, i havn't ever used it so i can't give you any advice on using it. But essentialy it shows the basics of reading from the console. (But if it doesn't do what you want, you can always adapt it, one of the useful things about having an open source library :))
Posted on 2001-01-01 15:29:00 by randy
Heres what I use hope it helps .Data EndOfLine db 13 .code LoadLine Proc Push ebx Push ecx Push esi Push edi mov ebx, eax Push ebx invoke InString,eax,pMemory,ADDR EndOfLine Pop ebx sub eax, ebx Push eax lea edi, buffer[0] mov esi, pMemory add esi, ebx dec esi inc eax sub eax, ebx mov byte ptr [0],0 mov ecx, eax MemCpy: mov al, byte ptr [-1] mov byte ptr [-1], al dec ecx jnz MemCpy Pop eax add eax, 3 Pop edi Pop esi Pop ecx Pop ebx ret LoadLine EndP Thip assume pMemory points to the file eax as the start position in the file buffer will contain the line. Zadkiel
Posted on 2001-01-02 18:10:00 by Zadkiel