LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 138
Default format last row on sheet with VBA macro

JMB;
I have tried this code and I get an error and it goes into debug mode. I
have typed the macro exactly as you have it. I did change Sheet2 to Sheet1.
As a side note, how would I default this to the active sheet?
Thanks - Bruce
--
VBA Rookie


"JMB" wrote:

This should find the last cell in Col A that has an entry. Then changes the
font in column A-H to bold for that row. Modify to use whatever formatting
you wanted.

Sub test()
With Worksheets("Sheet2")
With .Cells(.Rows.Count, 1).End(xlUp).Resize(1, 8)
.Font.Bold = True
End With
End With
End Sub


"Calle" wrote:

Hi!
Is it possible for a macro to format the last row from say A-H in a
worksheet. I can't do this manually since the length of the worksheet changes
from time to time.

Regards Calle

 
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
Macro to format a sheet danh Excel Programming 0 June 19th 06 05:25 AM
How do I format a sheet using a copy macro? Nimbus55 Excel Programming 1 April 1st 06 04:46 AM
can I clean old excel data format with macro on funny spread sheet Todd F.[_2_] Excel Programming 0 July 22nd 05 09:15 PM
How do I copy a print format from sheet to sheet in excel ? kernat Excel Discussion (Misc queries) 1 July 22nd 05 04:59 PM
Can a macro format a hidden sheet? Robert Excel Discussion (Misc queries) 1 February 9th 05 06:13 PM


All times are GMT +1. The time now is 12:37 PM.

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"