ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Using Object model to start an instance of excel on another computer? (https://www.excelbanter.com/excel-programming/358746-using-object-model-start-instance-excel-another-computer.html)

P

Using Object model to start an instance of excel on another computer?
 
Hi everybody, thanks in advance for the feedback.
I am automating some excel sheets from VB. What I have now is the
below code that calls up an excel sheet and sets it running. This works
great when everything runs locally on my comp. Code below:

Sub foo()
Dim bar As Object
Dim ws As Object
Set bar = CreateObject("Excel.Application")
bar.Visible = True
Set ws = bar.Workbooks.Open("C:\Documents and Settings\p\My
Documents\book1.xls")
bar.Run "thisworkbook.doAnalysis"

End Sub

Is there any way to make the isntance of excel come up and start
running on a different computer?

I've tried this for the createObject call but it doesn't seem to be
working:

Set bar = CreateObject("Excel.Application", "otherCompName")

Any ideas?
Thanks,
P


P

Using Object model to start an instance of excel on another comput
 
Thanks Kim, I'll take a look at your stuff!



All times are GMT +1. The time now is 01:23 PM.

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