I need TextFile algo, like GetText, OpenFile etc.
Thanks.
Thanks.
Here is the code, but it does not work.
This code must able to place all line offset on a memory.
CreateOffsetTable proc uses esi edi ebx lpSou:dword,lpTbl:dword,FileSize:dword,lnCnt:dword
;LOCAL rslt,Pos:dword
mov esi,lpSou
mov edi,lpTbl
xor ecx,ecx
mov [edi],ecx ; << 1st line at 0 offset.
add edi,4
dloop:
mov bl,[esi]
cmp bl,10 ; << if 0a it mean end of Line
jnz go
inc eax
mov [edi],ecx ; place the offset to lpTable pointed by edi
add edi,4
go:
inc esi
inc ecx
cmp ecx,FileSize
jl dloop
ret
CreateOffsetTable endp
This code must able to place all line offset on a memory.
Here is the code, but it does not work.
I got such alot :grin:
to me it looks like your testing a string that ends with the return hex of 0a0d... but not all programs use 0a0d for the parsing of return... some only use one byte.. i dont know what your exactly trying to do though please explain more..
It only mark offset of a Line. It only for standard text format. I think it only use 0xd. not 0x0d0a.
It working now, I miss-offset buffered it.
It working now, I miss-offset buffered it.