Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel Recalculate

Status
Not open for further replies.

runals

Technical User
May 20, 2005
11
0
0
US
Hello,

I am manipulating an Excel sheet with VB6. In the workbook there are formulas - specifically "sumif" that should be recalculating some cells. As I add data via the VB program the recalculation does not take place. I have made the workbook sharable, but excel is closed at the time of update.

The question is can I use the formulas in the worksheet to return the proper values or must I go and write routines in VB to accomplish the same thing?


Thanks in advance

Andy
 
Yes, you can use the formulas in the worksheet. When you instantiate an instance of Excel and use the app open function, it is opening excel, even though it's not visible. While it's open you can access any part of the spreadsheet by referencing the proper row and column.
 
Thanks for the reply.

That is what i though should happen. However the recalculation is not happening. I don't know if I am running into a buffer problem or not. Is there a way to force recalculation? I am using ADO BTW.


thanks

Andy
 
There is, but I can't remember what it is off the top of my head. If you go to MSDN and do a search for Excel Application Server it will give you a listing of all the methods available
 
The Application or Worksheet object's Calculate method
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top