Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Microsoft ADO Ext. 2.5 vs. 2.6 for DDL...

I have a VBA program written in Excel 97 on one machine
(machine A) with a reference pointing to ADO Ext. 2.5 for
Security and DDL. The VBA program was modified on another
machine (machine B) also running Excel 97 but with a
reference to ADO Ext. 2.6...instead.

After the modifications on machine B, the reference is no
longer ADO Ext. 2.5 and changed to pointing to ADO Ext.
2.6 now.

When re-running it on machine A, the program gave many
errors and the reference was showing "Missing ADO Ext. 2.6
for Security and DDL".

My question was how to change the settings on either of
the machines to make the program work again on machine A.
Is there anyway to downgrade to ADO Ext. 2.5 for Security
and DDL to make it run well on machine A?

Thanks a lot!

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default Microsoft ADO Ext. 2.5 vs. 2.6 for DDL...

"Derek Richards" wrote in
:

I have a VBA program written in Excel 97 on one machine
(machine A) with a reference pointing to ADO Ext. 2.5 for
Security and DDL. The VBA program was modified on another
machine (machine B) also running Excel 97 but with a
reference to ADO Ext. 2.6...instead.

After the modifications on machine B, the reference is no
longer ADO Ext. 2.5 and changed to pointing to ADO Ext.
2.6 now.

When re-running it on machine A, the program gave many
errors and the reference was showing "Missing ADO Ext. 2.6
for Security and DDL".

My question was how to change the settings on either of
the machines to make the program work again on machine A.
Is there anyway to downgrade to ADO Ext. 2.5 for Security
and DDL to make it run well on machine A?

Thanks a lot!



I ran into a similar problem when developing on a Windows XP machine for
deployment on Windows 2000 machines. XP has the ADO ext 2.7 installed as
part of the core system which created problems since the other machines
only had 2.5 installed.

The only resolution I found was to use late-binding for the ADO
Extensibility objects. Even though it isn't the best solution, it might
be the only one if you can't get everyone running the same version of ADO.

HTH!

--
Andrew Mauer
----------------
To reply directly, remove .nospam from email
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 459
Default Microsoft ADO Ext. 2.5 vs. 2.6 for DDL...

I disagree. I think late binding *is* the best solution.

--

Andrew Mauer wrote in message . 248.16...
"Derek Richards" wrote in
:

I have a VBA program written in Excel 97 on one machine
(machine A) with a reference pointing to ADO Ext. 2.5 for
Security and DDL. The VBA program was modified on another
machine (machine B) also running Excel 97 but with a
reference to ADO Ext. 2.6...instead.

After the modifications on machine B, the reference is no
longer ADO Ext. 2.5 and changed to pointing to ADO Ext.
2.6 now.

When re-running it on machine A, the program gave many
errors and the reference was showing "Missing ADO Ext. 2.6
for Security and DDL".

My question was how to change the settings on either of
the machines to make the program work again on machine A.
Is there anyway to downgrade to ADO Ext. 2.5 for Security
and DDL to make it run well on machine A?

Thanks a lot!



I ran into a similar problem when developing on a Windows XP machine for
deployment on Windows 2000 machines. XP has the ADO ext 2.7 installed as
part of the core system which created problems since the other machines
only had 2.5 installed.

The only resolution I found was to use late-binding for the ADO
Extensibility objects. Even though it isn't the best solution, it might
be the only one if you can't get everyone running the same version of ADO.

HTH!

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default Microsoft ADO Ext. 2.5 vs. 2.6 for DDL...

Thanks for all of you. How to use the late binding in
detailed steps?


-----Original Message-----
I disagree. I think late binding *is* the best solution.

--

Andrew Mauer wrote in

message
. 248.16..
..
"Derek Richards"

wrote in
:

I have a VBA program written in Excel 97 on one

machine
(machine A) with a reference pointing to ADO Ext. 2.5

for
Security and DDL. The VBA program was modified on

another
machine (machine B) also running Excel 97 but with a
reference to ADO Ext. 2.6...instead.

After the modifications on machine B, the reference

is no
longer ADO Ext. 2.5 and changed to pointing to ADO

Ext.
2.6 now.

When re-running it on machine A, the program gave

many
errors and the reference was showing "Missing ADO

Ext. 2.6
for Security and DDL".

My question was how to change the settings on either

of
the machines to make the program work again on

machine A.
Is there anyway to downgrade to ADO Ext. 2.5 for

Security
and DDL to make it run well on machine A?

Thanks a lot!



I ran into a similar problem when developing on a

Windows XP machine for
deployment on Windows 2000 machines. XP has the ADO

ext 2.7 installed as
part of the core system which created problems since

the other machines
only had 2.5 installed.

The only resolution I found was to use late-binding for

the ADO
Extensibility objects. Even though it isn't the best

solution, it might
be the only one if you can't get everyone running the

same version of ADO.

HTH!

.

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 459
Default Microsoft ADO Ext. 2.5 vs. 2.6 for DDL...

In a nutshell, to change from early to late bound:

• replace variables dim'ed with class name with Object type;
• replace instantiation (New keyword) with CreateObject;
• replace enumerations with constants.

Here's some example code. The two procedures are the same but for binding:

Sub TestEarlyBound()

Dim oConn As ADODB.Connection
Dim oRs As ADODB.Recordset
Dim strSql As String

Set oConn = New ADODB.Connection

With oConn
.CursorLocation = adUseClient
.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=" & strPATH
.Open
End With

strSql = "SELECT RefID, Surname" & _
" FROM PersonalDetails"

Set oRs = oConn.Execute(strSql)

' <code

oRs.Close
oConn.Close

End Sub

Sub TestLateBound()

Dim oConn As Object
Dim oRs As Object
Dim strSql As String

Set oConn = CreateObject("ADODB.Connection")

With oConn
.CursorLocation = 3 ' adUseClient
.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=" & strPATH
.Open
End With

strSql = "SELECT RefID, Surname" & _
" FROM PersonalDetails"

Set oRs = oConn.Execute(strSql)

' <code

oRs.Close
oConn.Close

End Sub

--

"Derek" wrote in message ...
Thanks for all of you. How to use the late binding in
detailed steps?


-----Original Message-----
I disagree. I think late binding *is* the best solution.

--

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I covert Microsoft Word file into Microsoft Excel one? KatK Excel Discussion (Misc queries) 1 April 3rd 08 04:57 PM
Microsoft Visual Basic errors displaid when opening Microsoft Word 97 & Excel (7 JJ mac Setting up and Configuration of Excel 7 June 14th 07 06:54 PM
Relation Microsoft Access avec Microsoft Excel Mounir Excel Discussion (Misc queries) 2 August 23rd 06 10:43 AM
Change individual cell heights/widths in Microsoft Excel 2000 like Microsoft Word urbanplanner Excel Discussion (Misc queries) 3 December 7th 05 03:57 PM
How do I import Microsoft Word files into Microsoft Excel? Excel New Users to Excel 1 January 9th 05 01:03 AM


All times are GMT +1. The time now is 05:24 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"