LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Functions and Ranges

The following code is an exerpt from an Access module that drops records into Excel. Once in Excel I want to run functions on the entire column of data like sum(c1:c52), but come up with errors. Any thoughts? Thanks in advance, Forrest

' to the Microsoft Excel spreadsheet.
Do Until Rs.EOF
For i = 0 To Rs.Fields.Count - 1
CurrentField = Rs(i)
Sheet.cells(j, i + 1).Value = CurrentField
Next i
Rs.MoveNext
j = j + 1
Loop

' Sum range of cells.
Sheet.cells(j, i).Value = Sheet.range("C50").Value + _
Sheet.range("c51").Value


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
If functions Looking at ranges Baba Excel Discussion (Misc queries) 3 May 10th 07 05:43 PM
IF functions and Names Ranges JaB Excel Discussion (Misc queries) 1 January 18th 07 12:30 PM
Copy and SUM functions with different ranges Manos Excel Worksheet Functions 1 July 1st 06 08:16 AM
if functions with more than 7 ifs (ranges are possible?) irwinko Excel Worksheet Functions 3 May 17th 05 12:57 PM
Functions and Ranges Ian Mangelsdorf Excel Programming 1 December 3rd 03 07:02 AM


All times are GMT +1. The time now is 08:22 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"