Hello Scott,

> I would like to
> have one sub routine such as
> save copy C:\city.tab as E:\temp\city.tab
> in which the input variable city would represent the variable
> that the user has selected

You can use your CITY variable in an expression in table processing
commands. However, there is no "save copy" type command in MI. The easiest
thing to so is to open the selected table and save it again.

open table "c:\"+CITY as TO_COPY_SAVE
commit table TO_COPY_SAVE as "e:\"+CITY

With open and commit, you do not need to put ".tab" extensions in the
expression as MI assumes it. Also, it would be wise to have your directory
paths implemented as variables rather than hard-coded and also to check for
the existence of the copy table before attempting the copy. You can do this
with the FileExists() function.

Regards,
Warren Vick
Europa Technologies Ltd, U.K.
http://www.europa-tech.com

----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]

Reply via email to