Solved

Visual Basic connect to Excel file

Posted on 2013-01-30
3
397 Views
Last Modified: 2013-01-31
In order ro connect the Excel file will I need Excel installed on my computer.
See code below.

Private m_oXlsTests As ADODB.Connection
Private m_oRdsTest As ADODB.Connection

   Set m_oXlsTests = New ADODB.Connection
    With m_oXlsTests
        .Provider = "Microsoft.Jet.OLEDB.4.0"
        .Properties("Extended Properties") = "Excel 8.0"
        strFileName = App.path & "\Tests.xls"
        .Open strFileName
    End With
0
Comment
Question by:Idarac
[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 85

Expert Comment

by:Rory Archibald
ID: 38838722
No, that should not require Excel.
0
 
LVL 9

Accepted Solution

by:
shorvath earned 500 total points
ID: 38839088
You do not require Excel to be installed on a system in order to use ADO to read and write data in Excel workbooks.

http://support.microsoft.com/kb/278973

For a detailed article using VB6 ADO and Excel see this link:

http://support.microsoft.com/kb/257819
0
 
LVL 1

Author Closing Comment

by:Idarac
ID: 38839494
Perfect
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

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

You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
How to get Spreadsheet Compare 2016 working with the 64 bit version of Office 2016
This Micro Tutorial will demonstrate how to use a scrolling table in Microsoft Excel using the INDEX function.
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

690 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