Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Setup / April 2005

Tip: Looking for answers? Try searching our database.

Finding last cell with data in a column

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Nigel Bennett - 28 Apr 2005 14:23 GMT
I am looking for something that will find the last cell of
data in a column, here is what I want to do

the function I have is

=if(a1=0,0,(b1-$cS10)*d1)

C10 is the total for that column

now that works fine on sheet 1 but on sheet 2 and then
sheet the total is in cell C23, due to the nature of the
spreadsheets I am coding it so the formulas get entered
each time by clicking a button. How do I find the last
cell containing data in column C and then use it in the
formula. Once I can find it on one sheet then I can find
it on the rest

Thanks
anonymous@discussions.microsoft.com - 29 Apr 2005 17:59 GMT
http://www.xldynamic.com/source/xld.LastValue.html#vba

>-----Original Message-----
>I am looking for something that will find the last cell of
[quoted text clipped - 16 lines]
>Thanks
>.
zackb - 29 Apr 2005 20:03 GMT
You may also want to look here:

http://www.vbaexpress.com/kb/getarticle.php?kb_id=417

http://www.vbaexpress.com/kb/getarticle.php?kb_id=418

You can disregards everything except the functions 'xlLastRow' and
'xlLastCol'.

Although I'd suggest changing one line in each UDF ..

    WorksheetName = ActiveSheet.Name

.. change to ..

   WorksheetName = Application.Caller.Parent.Name

This ensures that the function will work in the worksheet setting and not
just in the VBA environment.

Signature

Regards,
Zack Barresse, aka firefytr

>I am looking for something that will find the last cell of
> data in a column, here is what I want to do
[quoted text clipped - 14 lines]
>
> Thanks

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.