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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Edit Excel cell from Access?

Status
Not open for further replies.

JR2913

MIS
Sep 21, 2002
115
GB
Is it possible to change the content of a cell in an Excel spreadsheet from code within Access?

I have a number of spreadsheet files that need to be imported but the heading of one column is incorrect and needs changing to "SENStatus" before I use the Transferspreadsheet command to put the data into the table that exists in the back-end database. At the moment it is creating an error as the column heading doesn't match this existing field name, so I can't import the data.

Any advice on how to do this from within VB would be much appreciated.


John R
 
You have to set up a reference to the Excel object model in code to do this. Can you work in VBA at that level?
 
Yep....... must be brain dead this afternoon, as I have done this before. Just couldn't get my head round it to start with.

Thanks

John R
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top