You could do it like this
'''''---------------code--------------------
include "mapbasic.def"
Declare Sub Main
Sub Main
Dim strFile As String
Dim origTableName As String
Dim newFileName As String
strFile = FileOpenDlg("","","TAB","Open TAble")
Open Table strFile
origTableName = TableInfo(0,TAB_INFO_NAME)
Commit Table origTableName As origTableName & "_trk"
End Sub
''''---------------end code--------------------
-----Original Message-----
From: Kevin Slover [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, October 15, 2002 6:07 AM
To: Directionsmag
Subject: MI-L FileOpenDlg Question
I am using the FileOpenDlg to open a file, register the file, and then
doing a "Commit As" to save the file under a different name to be able
to manipulate the file. What I am wondering is if there is a way to
save the file as the original file name, plus an extension. Example:
szOpenTable = FileOpenDlg(ProgramDirectory$() + ...
Then, I would like to save the table as szOpenTable_trk. Basically, I
wish to keep the file name, add an extension, and save. And ideas?
--
LTJG Kevin Slover, NOAA
GIS Specialist/Oceanographer
NOAA/TPC/TSB/Storm Surge Unit
11691 SW 17th Street
Miami FL 33165
W (305) 229-4456
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 3580
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 3586