• Please review our updated Terms and Rules here

Table file open error on TASM

jacobtohahn

Experienced Member
Joined
May 1, 2018
Messages
79
Location
North Carolina, USA
Hi,
I've been using TASM 3.2 to assemble files just fine for a while now, but today I'm having a very strange issue. I have a batch script set up that runs TASM to assemble a couple of files for a Z80. Thus, I have the table file "TASM80.TAB".
For organization reasons, I have TASM in a different subdirectory of the parent directory that my assembly files are located in, like this:

PARENT DIR
____|____
| . . . . . . . |
TASM. . .ASM

The batch file is located in the same subdirectory as the assembly files, and uses a relative path to run TASM (..\TASM\TASM.EXE). This has been working fine.
However, today I moved the parent directory to a new folder. Because the batch file uses a relative path, I believed it would still work fine (as it should). However, now whenever I run the batch file, I receive this error:

C:\Users\*****\OneDrive\Documents\GitHub\ZTO-80\Code\BASIC> ..\tasm32\tasm -80 -fff -c bas32k.asm bas32k.hex
tasm: table file open error on C:\Users\*****\OneDrive\Code\Z80\ASM\tasm32/tasm80.tab

This is very odd. The path before the > is the new assembly directory, where the batch is running. However, the path that it says that it is having the error on (second line) is the old tasm folder. That old folder no longer exists, because I deleted it. There is no file telling it to look for the table file there, yet even after restarting my PC it still looks there, so it has to remember it somehow!

I have already tried putting the table file in the same directory as my assembly files (although I don't think that was the issue, as it ran fine before without it in the same directory), and I have tried deleting the table file and TASM executable and replacing them with fresh replacements, but neither worked.

Is there some way that I can tell TASM to look in its own directory for the table file? And is there a reason that it seems to be remembering the old location?

Thanks.
 
Solved! Apparently, TASM creates a system environment variable called "TASMTABS" pointing to the path where the table files are located. Hopefully this helps someone else in the future.
 
Back
Top