Sharon,
It is quite possible that ODBC support isn't installed. It is a real pain
when supporting MapInfo because the installation of ODBC support is separate
from the rest of the program.
On the CD (MI5) MI5 program files are installed from:-
...\Install\MI_Pro
ODBC support is installed from:-
...\install\ODBC

If ODBC Support isn't installed then under >File the Open ODBC.. will be
grayed out.

_________________________________________________________

If you have MI5, DAO - Direct Access to MS Access tables is now supported
therefore you should be able to open directly a live access table.
As far as OLE and DDE a good introduction is the use of OLE automation, Try
the following in Access:-

1: Create a new database then a new form.

2: View design and then View>Code and under the Form_Load type (or cut and
paste from here):-

Private Sub Form_Load()
On Error GoTo create_error
Set mapinfo = GetObject(, "mapinfo.application")
    'create OLE app to communicate with
create_error:
    ' if you are here it means that the " GetObject call failed
    ' and so you will need to make a new instance using
    ' CreateObject
    Set mapinfo = CreateObject("mapinfo.application")

What this does is produces an instance of MapInfo through OLE automation. If
you are running NT - check out in the Task Manager - Processes and see if
you have Mapinfow.exe listed

3: At the top of the code page type:-

Dim mapinfo As Object

4: In form_load type the following - This loads the standard Mapinfow
workspace stored in your Windows directory

mapinfo.do "run application homedirectory$()+""\mapinfow.wor"" "

Or

Mapinfo.do "open Table ""World.tab"" interactive"


5: If you create a button on the from and right-click to build an event type
the following:-

Mapinfo.Visible = True

In your task bar you should have MapInfo now showing, By maximising it and
going to Close Table or new map window you may see if your tables are open.
To hide MI5 you can use a button with Mapinfo.Visible = False.


6: The really clever stuff comes when using ODBC. Set up under control Panel
an ODBC dataset:- 

Under system DSN - Set up a name for a DSN and navigate to an Access
database with a table in.
Name the DSN:-  MapinfoData with a table called Table1 (Or adjust the
following names)

7: Try the following syntax (either in the form load or on a button)

                qry = """select * from Table1"""
                dostmt = "Server Link Table "
                dostmt = dostmt & qry
                dostmt = dostmt & "Using ""DSN=MapInfoData""  into
""Table1"" "
                MapInfo.do dostmt

This creates a MapBasic Command but executed through Access:- (Server Link
Table Select * from Table1 Using "DSN=MapInfoData" into "Table1")

8: If you view MapInfo again (Using the Mapinfo.Visible = True or a button)
you should be able to go to new browser window and view the Downloaded data.
Using this approach you can edit the data in MI or in Access and you will
always be looking at the same set of data.

9: This approach may seem quite strange with the MapInfo.Visible business
but there exists ways of (WARNING GOOBLEDEEGOOK!) "Reparenting a Window
using the Windows Hwnd" (this uses the following type of code if you have an
image window or an OCX control that supports Hwnd):-

MapInfo.do "set next Document Parent " & mapwin.Hwnd & " Style 1"

(Where MapWin is the name of the image window or OCX)
It is quite likely that you wouldn't have anything that supports this but
give it a go any way!

As Far as DDE goes check out the URL recommend recently:-

http://testdrive.mapinfo.com/tdc/home.nsf/c3d4b43ae3050d7d8525647900631dd3/8
9cfd7b5219fb3b4852564880047191f?OpenDocument

This will give you info as how to employ DDE in an Integrated Mapping
environment, It will also explain general Integrated Mapping Concepts in
more detal than here (but it mostly caters for those with VB or VisC++)

As far as futher avenues of study see if you can find any information about
OLE Db - A new concept that Microsft is promoting and should be supported by
MI, but I have yet to use it.

Any more problems, etc please do not hesitate to contact me.

Tim Chinchen (IT Services) (01202) 454723
mailto:[EMAIL PROTECTED]




> -----Original Message-----
> From: Sharon Murray [SMTP:[EMAIL PROTECTED]]
> Sent: Wednesday, May 26, 1999 10:55 PM
> To:   [EMAIL PROTECTED]
> Subject:      MI Re-post - Desperately seeking Help with MapInfo
> 
> I'm re-posting this message, originally posted yesterday, as I don't think
> it was sent successfully. Apologies if I'm wrong.
> 
> Can anybody help me. I am a complete beginner with MapInfo, but I need to
> know how to create a link between MapInfo and Access in each of the
> following ways: ODBC connection, DDE link, OLE links. I need this for the
> purposes of an academic assignment (no one is paying me to be so useless
> !).
> 
> All I want to do is to open an Access table in MapInfo and edit it, and
> for
> those changes I have made to be seen n Access. Likewise, for changes made
> in
> Access to be seen in MapInfo.
> 
> I know it can be done using the interface - I have already done it, but
> the
> trouble is I'm not sure what method is being used. I thought it was ODBC,
> but none of the ODBC options - eg refresh - are available (or even
> present)
> on any of the menus.
> 
> If anyone can help describe what the interface is doing, or better still
> give me step by step instructions of how to apply those 3 methods in
> MapInfo, I would be very very grateful.
> 
> Please help,
> 
> Sharon
> 
> ----------------------------------------------------------------------
> To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
> "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]



**********************************************************************
This email and any files transmitted with it are confidential and 
intended solely for the use of the individual or entity to whom they   
are addressed. If you have received this email in error please notify 
the system manager.

This footnote also confirms that this email message has been swept by 
MIMEsweeper for the presence of computer viruses.

www.bournemouth.gov.uk
**********************************************************************


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