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: 1
Default Get Last Unused Cell

I am trying to get the last unused cell so that I can put a borde
around them. This is because my result set in the worksheet is dynami
and can contain more or less values. Right now I have macro hard-codin
the last cell in the range:
Range("A1:H16").Select
Selection.Borders(xlDiagonalDown).LineStyle = xlNone
Selection.Borders(xlDiagonalUp).LineStyle = xlNone
With Selection.Borders(xlEdgeLeft)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With Selection.Borders(xlEdgeTop)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With Selection.Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With

How do I find he last unused cell in my range cell property? Thanks

--
Message posted from http://www.ExcelForum.com

 
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
Find column letter of the first unused cell John Excel Worksheet Functions 2 May 10th 09 09:06 PM
Copying to next unused row Ken[_2_] Excel Worksheet Functions 5 June 24th 08 08:11 AM
what to do with unused cells B Excel Worksheet Functions 1 June 22nd 06 12:09 AM
Code not going to next unused row goss[_30_] Excel Programming 2 August 9th 04 05:04 AM
find next unused row Mike[_33_] Excel Programming 2 July 16th 03 05:01 AM


All times are GMT +1. The time now is 06:21 PM.

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

About Us

"It's about Microsoft Excel"