Hi Serge,

The problem is that the object variables are converted into text in your
Run Command
Statement. And when you convert an object variable to text, you get the
type of object
the variable contains/is pointing at.
This also explains the error you are getting : "Variable og field Region
not defined.

The way I would solve this problem is by inserting your objects into a new
table and then
create the SQL statement using this table.

Like this:

***************************************************************************
*************
Dim i As Integer

'**Create a new table for the objects...
Create Table OBJECT_SQL
     (
     ID   Integer
     )
     File TempFileName$("")
'**Let's make the table mappable...
Create Map For OBJECT_SQL
     CoordSys Table gsGridUnderN

'**Inserting your first object...
Insert Into OBJECT_SQL (OBJ) Values (goCelluleModifiee)

'**Inserting all the objects in your array...
For i = 1 To Ubound(goCelluleFille)
     Insert Into OBJECT_SQL (OBJ) Values (goCelluleFille(i))
Next

'**Make the selection into FUSION
Select * From gsGridUnderN
     Where OBJ Contains Any (Select OBJ From OBJECT_SQL)
     Into Fusion

'**Do the rest of yor work with this table
....

'***Clean up the temp table:
Drop Table OBJECT_SQL
***************************************************************************
*************

I hope this helps you !

Best regards,

Peter
***************************************************************************
*
Peter Moller        [EMAIL PROTECTED]
GIS-Developer       Direct: +45 6313 5008
Kampsax        Voice: +45 6313 5013
Rugårdsvej 55       Faximile: +45 6313 5090
DK 5000 Odense C    Web: www.mapinfo.dk
MapInfo Authorized Partner
***************************************************************************
*


----------------------------------------------------------------------
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