Ben,
If you issue the split command as a commndstr created by a loop rather than the object split command directly, you can include all the data from the target, as follows:
strCommand = "Objects Split Into Target Data "
For i = 1 To NumCols(gEditFile)
strCommand = strCommand + ColumnInfo(gEditFile, "col"+i,COL_INFO_NAME) + " = " + ColumnInfo(gEditFile, "col"+i,COL_INFO_NAME) + ", "
Next
strCommand = Left$(strCommand, Len(strCommand) - 2)
Run Command strCommand
r
On Wed, 19 May 2004 16:03:15 +1000, Benjamin Scott <[EMAIL PROTECTED]> wrote:
Hi all,
I want to split a collection of tab files one by one using one master file - I am doing this within a For loop in mapbasic.
I need the data in the output tables to be the same as the input tables (ie all new objects in the split table have identical attributes to the object they were split from). The Objects Split command only seems to have the option to leave all columns blank or to specify the particular columns that are equal pre and post the split - there doesn't seem to be an option to say "I want all columns to be equal to the attributes before the split"
Is that true or is there a method I am unaware of?
One complication is that the number of columns and the name of each column is different for each tab file.
Regards,
Ben Scott Environmental GIS Analyst City Solutions Blue Mountains City Council (02) 4780 5433
--------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 11834
--
Robert Crossley Agtrix P/L 9 Short St PO Box 63 New Brighton 2483 Far Southern Queensland AUSTRALIA
153.549004 E 28.517344 S
P: 02 6680 1309 F: New Connection M: 0419 718 642 E: [EMAIL PROTECTED] W: www.agtrix.com W: www.wotzhere.com
--------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 11835
