Malcolm,
>I assume this means that where you have "long argument", I would put a data type specific arg for each value being passed to sprintf?
>
>In other words, if I had a number and a string I would replace "long argument" with something like "long arg1, string arg2" ?
Exactly, VFP doesn't have any way of dealing with differing number of arguments or differing types. So you'll just have to re-declare it each time the argument list changes in size or type.
>BTW: I replaced ntdll.dll with msvcr71.dll (distributed as part of the runtime setup files) and your idea worked fine. I'm not sure if there are any downsides to using msvcr71.dll? I suggested it in case someone reading this thread needs to use your example on a 9X/ME workstation that will not have ntdll.dll available.
You probably need to make sure that dll gets included on your setup disks.