How to access Notes nsf from Ms Access using ODBC?

All the while we are doing accessing other databases from Notes thru ODBC.  How about if I want to access Notes .nsf thru a Ms Access database?  How to do it?
n_chaiAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

blakeh1Commented:
You can use the notes sql odbc driver to set up an odbc connection or even link directly to Access, or could use vba to Access directly. below is an example that will take contacts from an access database and enter that into the Personal Address book into notes
Sub usbexportaddress()
    Const ntsserver = "" 'Use empty string if it is a local database
                          'else use the server/domain ex: notes46/pc46
    Const ntsmailFile = "names.nsf"
    Dim db As Database
    Dim rst As Recordset
    Dim strAddr As String
   
    Dim osess As Object
    Dim oDb As Object
    Dim oDoc As Object
    Dim v As Variant
       
    Set db = CurrentDb()
    Set rst = db.OpenRecordset("myadddressbook")
    rst.MoveFirst
    Set osess = CreateObject("Notes.NotesSession")
    Set oDb = osess.getdatabase(ntsserver, ntsmailFile)
On Error GoTo err_usbaddressbook
   
Dim strFirst As String
    Dim strLast As String
   
    Dim strAddr As String
   
    Do While Not rst.EOF
        strFirst = rst("FirstName")
        strLast = rst("LastName")
        strAddr = rst("MailAddress")
        Set oDoc = oDb.CreateDocument
        oDoc.Form = "Business Card"
        Dim retval As Variant
       
        oDoc.FirstName = strFirst
'notes field is an array of variants or strings
        'MsgBox retval(0)
        oDoc.LastName = strLast
        oDoc.MailAddress = strAddr
        oDoc.FullName = strFirst & " " & strLast
        oDoc.Type = "Person"
        Call oDoc.Save(True, True)
       
        Set oDoc = Nothing
        rst.MoveNext
    Loop
exit_usbaddressbook:
    Set rst = Nothing
    Set db = Nothing
    Set oDoc = Nothing
    Set oDb = Nothing
    Set osess = Nothing
   
    Exit Sub
err_usbaddressbook:
       
    MsgBox Err.Number & " " & Err.Description
    Resume exit_usbaddressbook
End Sub
any questions? hope this helps
0
agvaCommented:
Hy,
you can use a tool which will do this job automaticly. Please look about this tool at:
http://www.acc-technology.com/ntwiz.htm
Rgds
Gunter
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
eiyengarsCommented:
Can I do the other way round?
I want to import data from NSF to Access?
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Lotus IBM

From novice to tech pro — start learning today.