Question: 4. Show File Attributes Write a procedure named ShowFileAttributes that receives the offset of a filename in DX and displays the files attributes in the

4. Show File Attributes Write a procedure named ShowFileAttributes that receives the offset of a filename in DX and displays the file’s attributes in the console window. Attributes to look for are normal, hidden, read-only, and system. Hint: Use INT 21h Function 7143h.

Write a program that calls ShowFileAttributes, passing it the name of a file. Before running your program, set the file attributes from Windows Explorer by right-clicking on the filename, selecting Properties, and checking the Hidden and Read-Only options. Alternatively, you can run the Attrib command from the Windows command prompt. Run your program and verify that the attribute display is correct. Sample output:

temp.txt attributes: Hidden Read-only

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 Implementing Programming Languages Questions!