[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Integrating Outlook2000 with either Access or MSSQL

Posted on 2000-02-24
3
Medium Priority
?
213 Views
Last Modified: 2010-04-08
I am trying to integrate Outlook2000 with both Access and Microsoft SQL Server.
I know it can be done ith ADO, but all the stuff I can find at Microsoft and other places, seem to assume a level of understanding that I just do NOT have.
If anyone can help me here with either samples or working code fragments, it would be really helpful.
0
Comment
Question by:Matlock
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 16

Expert Comment

by:Neo_mvps
ID: 2556418
I'm not sure if this will help or hinder you, but give http://www.slipstick.com/dev/database.htm a peek.
0
 
LVL 6

Accepted Solution

by:
Jon_Raymond earned 300 total points
ID: 2556590
What level do you have?  You have to know a minimum of programming fundamentals, like referencing the outlook object from VB or referencing Access from outlook (which one are you trying to do?).  You have to know how to make a connection either way.  This is basically simple.  You dim the ADO connection and recordset objects then go to work:


    Dim iRow As Integer
    Dim iCol As Integer
    Dim rs As ADODB.Recordset
    Dim conn As ADODB.Connection
    Dim strCnn As String
    ' Open a connection using a DSN and ODBC tags.
    Set conn = New ADODB.Connection
    'conn.ConnectionString = "DSN=SLXDSN;UID=sysdba;pw=masterkey"
    conn.Open "DSN=SLXDSN"
    strCnn = "Provider=sqloledb;server = JONRWIN98;" _
        & "uid=sa;pwd=;database=pubs"
    If conn Is Nothing Then
        Set conn = New ADODB.Connection
    End If
    Set rs = New ADODB.Recordset
    rs.Open "dbo.spTestIndex_Employee", strCnn, adOpenDynamic, adLockPessimistic
    ' use Getrows to put the recordset into an array:
    vCurrentArray = rs.GetRows(10, iRecordNumber)
    ' if you don't use getrows you can do this with a recordset
    ' from a stored procedure that limits the rows returned
    'with the same parameters that getrows uses:
   
    'Do While Not rs.EOF
    '    For iCol = 0 To 2
    '       vCurrentArray(iCol, iRow) = rs(iCol)
    '    Next                'iCol
    '    rs.MoveNext'
    'Loop
   
    'or loop through the recordset itself:
    With rs
        Do While Not .EOF
            'do some thing here with each record:
            vVariable1 = rs(0) ' the first field by number or
            vVariable2 = rs("Field 2") ' the second field by its name in quotes
        Loop
    End With
   
   
For samples of how to manipulate Outlook objects see:
http://www.microsoft.com/outlookdev/articles/outprog.htm

If this is too complicated then coding isn't for you.
0
 

Author Comment

by:Matlock
ID: 2565102
Thanks to both Neo_mvps
 and Jon Raymond, both bits were helpful but I have Accepted Jon's comment as the answer as I have been able to modify his code to make my application ( A VBScript behind an Outlook form to read from SQL7)

Coding isn't the problem, but moving from C/C++ to VB can be ....
0

Featured Post

Nothing ever in the clear!

This technical paper will help you implement VMware’s VM encryption as well as implement Veeam encryption which together will achieve the nothing ever in the clear goal. If a bad guy steals VMs, backups or traffic they get nothing.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to import an Outlook PST file to Office 365 using a third party product to avoid Microsoft's Azure command line tool, saving you time.
This article will help to fix the below errors for MS Exchange Server 2013 I. Certificate error "name on the security certificate is invalid or does not match the name of the site" II. Out of Office not working III. Make Internal URLs and Externa…
CodeTwo Sync for iCloud (http://www.codetwo.com/sync-for-icloud?sts=6554) automatically synchronizes your Outlook 2016, 2013, 2010 or 2007 folders with iCloud folders available via iCloud Control Panel. This lets you automatically sync them with…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question