ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   DDE Startup Hangs (https://www.excelbanter.com/excel-programming/316316-dde-startup-hangs.html)

amac

DDE Startup Hangs
 
Hello,

I have the following code in my script:
excelpath = "c:\msoffice\office\Excel.exe"
Z = Shell(excelpath, 1) ' Start Microsoft Excel.
If Err.Number Then Exit Sub
ExcelLink.LinkTopic = "Excel|System" ' Set link topic.
ExcelLink.LinkItem = "R1C1" ' Set link item.
ExcelLink.LinkMode = 2 'vbLinkManual ' Set link mode.

after those statements other things happen in excel.

Normally this works fine, but on one specific computer (windows xp with SP1
and excel 2002) it hangs. When excel is started manually the program works
fine and all statements are executed.

Can somebody help me with this problem?

Dmoney

DDE Startup Hangs
 
Give this a shot - works in 2000

Dim APEXCEL As Object
Set APEXCEL = CreateObject("EXCEL.APPLICATION")
APEXCEL.Visible = True
APEXCEL.Workbooks.Open ("d:\userdata\book1.xls")

AppActivate APEXCEL
....update links

-----Original Message-----
Hello,

I have the following code in my script:
excelpath = "c:\msoffice\office\Excel.exe"
Z = Shell(excelpath, 1) ' Start

Microsoft Excel.
If Err.Number Then Exit Sub
ExcelLink.LinkTopic = "Excel|System" ' Set link topic.
ExcelLink.LinkItem = "R1C1" ' Set link item.
ExcelLink.LinkMode =

2 'vbLinkManual ' Set link mode.

after those statements other things happen in excel.

Normally this works fine, but on one specific computer

(windows xp with SP1
and excel 2002) it hangs. When excel is started manually

the program works
fine and all statements are executed.

Can somebody help me with this problem?
.



All times are GMT +1. The time now is 06:31 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com