Thanks to all that replied to my message yesterday:
Yeah,
I had indeed to many quotes. Removed them and it opens the tables. However,
when I open the table and want to show it in my a picture on a form by
issuing the Map From command I get an Error saying:
Numeric Value Required (The message comes from VB). I changed quotes and
syntax and if I enter a random string I get an eror message that says that
the table is not open (of course not). What's wrong with that one?
Code:
MyMapInfo.Do "Set Application Window " & frmMappers.OLE1.hwnd
'Picture on a form as container
MyMapInfo.Do "Set Next Document Parent " & frmMappers.OLE1.hwnd & "
Style 1"
msg = "Open Table "
msg = msg & Chr(34)
msg = msg & MapNameArray(i, 1, BrowserNo)
msg = msg & Chr(34)
msg = msg & " Interactive "
'Built the string to show the open tables as maps
msg2 = "Map From "
msg2 = msg2 & MapNameArray(i, 2, BrowserNo) 'Contains the table
name without extension
MsgBox msg2
'Get MapInfo to execute both strings
MyMapInfo.Do msg
MyMapInfo.Do msg2
Here comes the run time error. The strings seem to be okay and when I open
a table manually through the
MyMapInfo.runmenucommand M_file_open method it displays. If I then use the
layer control to add the abopve opened table it works. But not if I don't do
any manual stuff. (I ve got lots of table to open and can't so it manually,
and anyhow, it's a matter of principles.
Thanks
Harald Sch�lzel
Economist Civil Engineer
c/o SOPAC South Pacific Applied Geoscience Commission
Private Mail Bag
Suva, Fiji
Tel: Business (679) 381 377 private (679) 386 236
Fax: (679) 370 040
Mailto:[EMAIL PROTECTED]
URL: http://www.sopac.org.fj/wru
Mirror URL: http://www.sidsnet.org/pacific/sopac/wru
----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]