Solved

update excel file

Posted on 2000-03-13
2
135 Views
Last Modified: 2010-05-02
I need a vb program that can open
Excel file A and update all its links
in the background. (without user's
interaction)





0
Comment
Question by:yliu8
[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
  • 2
2 Comments
 

Accepted Solution

by:
mbah022100 earned 50 total points
ID: 2615001
A way to do this is:

Dim objExcel As Object

Set objExcel = CreateObject("Excel.Application")
objExcel.Workbooks.Open FileName:="Your file"


From this moment on you can do what ever excel can do. To find out what is possible, you can use Excel itself and record macro's to see what is possible.

If at debug time you want to see what your application is doing the following statement may help:

objExcel.Visible = True

To stop your excel session do the following:

objExcel.Quit
Set objExcel = Nothing

Hope this is what you wanted to know
0
 

Expert Comment

by:mbah022100
ID: 2615011
Don't stop debugging without setting the created object to nothing. This may result in leaving an unrelated excel session in memory.
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

733 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