Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 68
Default DCOM98 and EXCEL2000 collision

Try using late binding.

Instead of

Dim xl as Excel.Application

use

Dim xl as Object

then instantiate the object by using

Set xl = CreateObject("Excel.Application")


Don't forget to remove the Excel reference from your project otherwise
you'll be defeating the point of this.


--

Regards,


Bill Lunney
www.billlunney.com

"Milko Koparanov" wrote in message
...
I've written a short procedure in VS6, which opens a new
Excel2000 application and populates a Range object:

Private Sub Populate()
Dim xl As Excel.Application, i as Integer
Set xl = New Excel.Application
xl.Visible = True
xl.Workbooks.Add
For i = 1 To 100
xl.Cells(i, i) = i ^ 2
Next i
Set xl = Nothing
End Sub

It works perfectly under WindowsXP and Windows98. But if
you have DCOM98 installed on W98 OS, it breaks on
xl.Cells(i, i) = i ^ 2
row, messaging an AUTOMATION ERROR -2147417848(80010108).
It works exactly the same way with or without Office2000
SP3, and from a VBA module of MS Office2000.

Thanks for any suggestion why this could happen!

Milko Koparanov



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
why Excel2000 don't allow to write ldiaz Excel Discussion (Misc queries) 4 November 2nd 06 04:20 AM
Excel2000: The latest value Arvi Laanemets Excel Worksheet Functions 5 November 30th 05 02:39 PM
Printing in Excel2000? PaulM Excel Worksheet Functions 2 November 4th 05 01:38 AM
DCOM98 and EXCEL2000 collision patrick molloy Excel Programming 0 July 17th 03 01:19 PM
Excel2000 VB Help Problem! skc[_2_] Excel Programming 0 July 9th 03 11:08 AM


All times are GMT +1. The time now is 02:41 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"