Design Script for Nested Files - Font replacement - V8i SS4

Using V8i Select Series 4

I am trying to make a simple microstation design script that will print a different font than the original used in a nested reference file.

I have 

if ((file <> 0) AND (type == text)) then
font = 164
endif

As far as I know, this specifies to look into the non active file, look for any text, and replace it with my given font.

What am I doing wrong?

Thanks