Yes Kent, I think your point is moot. It would appear the terminals are dumb and the printers are networked.

acomire,
The code appears sound but obviously either there is something you're not telling us or there is no %clientname% set.

Your assumtion of how InStr() works is not entirely accurate. It searches anywhere within the strig and returns the offset of where it found it. None the less, it should still work.

You really should single step through the script in debug mode and check the vars as you go.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.