Question: Write a program in Assembly language using Irvine library (irvine32,inc) to read the data from the file and save it into 2D array. The content

Write a program in Assembly language using Irvine library (irvine32,inc) to read the data from the file and save it into 2D array. The content of the file should be like A,30,4.

the program should store 3 different data delimited by commas in 2D array.

//Reference for file read

ReadFile PROTO, hFile:HANDLE, ; input handle lpBuffer:PTR BYTE, ; ptr to buffer nNumberOfBytesToRead:DWORD, ; num bytes to read lpNumberOfBytesRead:PTR DWORD, ; bytes actually read lpOverlapped:PTR DWORD ; ptr to asynch info

//2D array

tableB BYTE 10h, 20h, 30h, 40h, 50h Rowsize = ($ - tableB) BYTE 60h, 70h, 80h, 90h, 0A0h BYTE 0B0h, 0C0h, 0D0h, 0E0h, 0F0h

row_index = 1 column_index = 2 mov ebx,OFFSET tableB ; table offset add ebx,RowSize * row_index ; row offset mov esi,column_index mov al,[ebx + esi] ; AL = 80h

Please post the output screen as proof that program will compile. Irvine library must be included.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!