Aug 2, 2001 #1 shavon Programmer Joined Jun 18, 2001 Messages 102 Location CA How do i insert a formula into an Excel spreadsheet from VB6 please? Thank you
Aug 2, 2001 #2 NipsMG Programmer Joined Dec 27, 2000 Messages 215 Location US well if you're referencing the excel spreadsheet through the excel object library.... i.e. Code: Dim oExcel As New Excel.Application Then all you need to do is set the cell's contents to the formula. Code: oExcel.Range("A1") = "=SUM(A1:A35)" Hope that helps! --NiPSMG Upvote 0 Downvote
well if you're referencing the excel spreadsheet through the excel object library.... i.e. Code: Dim oExcel As New Excel.Application Then all you need to do is set the cell's contents to the formula. Code: oExcel.Range("A1") = "=SUM(A1:A35)" Hope that helps! --NiPSMG