Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
How can I set up the procedure (formatting, macro, whatever) to place a
gridline every ten rows on my spreadsheets? Or, how can I get it to put a gridline at every TOTAL line, when I apply subtotals? I have EXCEL 97. |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
try this?
Sub insertline() For Each c In Range("a2:a100") If UCase(c) = "TOTAL" Then With c.Borders(xlEdgeBottom) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With End If Next c End Sub -- Don Guillett SalesAid Software "badfastfan" wrote in message ... How can I set up the procedure (formatting, macro, whatever) to place a gridline every ten rows on my spreadsheets? Or, how can I get it to put a gridline at every TOTAL line, when I apply subtotals? I have EXCEL 97. |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I could not get what you sent to work, but that is probalby me rather than
Excel. So I asked a couple others at work to look at it. After a few versions based on what you gave me, this is what we came up with to put a line every ten rows. Sub insertline() Dim x As Long For Each c In Rows x = x + 1 If x Mod 10 = 0 Then With c.Borders(xlEdgeBottom) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With End If Next c End Sub Thank you so much. "Don Guillett" wrote: try this? Sub insertline() For Each c In Range("a2:a100") If UCase(c) = "TOTAL" Then With c.Borders(xlEdgeBottom) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With End If Next c End Sub -- Don Guillett SalesAid Software "badfastfan" wrote in message ... How can I set up the procedure (formatting, macro, whatever) to place a gridline every ten rows on my spreadsheets? Or, how can I get it to put a gridline at every TOTAL line, when I apply subtotals? I have EXCEL 97. |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Yes it did exactly that. But I can deal with that, some of my spreadsheets
are over 35000 rows, so it is ok. And it does put the gridline across the entire line, rather than in just one column. So all is well. Again thank you for your help. "Don Guillett" wrote: What I sent was tested for any cell in col A that said Total or TOTAL or total. What you sent will put a line every 10 rows to the bottom of the workbook causing BLOAT. BAD!! -- Don Guillett SalesAid Software "badfastfan" wrote in message ... I could not get what you sent to work, but that is probalby me rather than Excel. So I asked a couple others at work to look at it. After a few versions based on what you gave me, this is what we came up with to put a line every ten rows. Sub insertline() Dim x As Long For Each c In Rows x = x + 1 If x Mod 10 = 0 Then With c.Borders(xlEdgeBottom) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With End If Next c End Sub Thank you so much. "Don Guillett" wrote: try this? Sub insertline() For Each c In Range("a2:a100") If UCase(c) = "TOTAL" Then With c.Borders(xlEdgeBottom) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With End If Next c End Sub -- Don Guillett SalesAid Software "badfastfan" wrote in message ... How can I set up the procedure (formatting, macro, whatever) to place a gridline every ten rows on my spreadsheets? Or, how can I get it to put a gridline at every TOTAL line, when I apply subtotals? I have EXCEL 97. |
#6
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
glad you are happy
-- Don Guillett SalesAid Software "badfastfan" wrote in message ... Yes it did exactly that. But I can deal with that, some of my spreadsheets are over 35000 rows, so it is ok. And it does put the gridline across the entire line, rather than in just one column. So all is well. Again thank you for your help. "Don Guillett" wrote: What I sent was tested for any cell in col A that said Total or TOTAL or total. What you sent will put a line every 10 rows to the bottom of the workbook causing BLOAT. BAD!! -- Don Guillett SalesAid Software "badfastfan" wrote in message ... I could not get what you sent to work, but that is probalby me rather than Excel. So I asked a couple others at work to look at it. After a few versions based on what you gave me, this is what we came up with to put a line every ten rows. Sub insertline() Dim x As Long For Each c In Rows x = x + 1 If x Mod 10 = 0 Then With c.Borders(xlEdgeBottom) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With End If Next c End Sub Thank you so much. "Don Guillett" wrote: try this? Sub insertline() For Each c In Range("a2:a100") If UCase(c) = "TOTAL" Then With c.Borders(xlEdgeBottom) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With End If Next c End Sub -- Don Guillett SalesAid Software "badfastfan" wrote in message ... How can I set up the procedure (formatting, macro, whatever) to place a gridline every ten rows on my spreadsheets? Or, how can I get it to put a gridline at every TOTAL line, when I apply subtotals? I have EXCEL 97. |
#7
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
You could add the gridlines with conditional formatting:
Turn off the gridlines (ToolsOptions, View tab) Select all the cells on the worksheet Choose FormatConditional Formatting From the first dropdown, choose Formula Is In the formula box, type: =MOD(ROW(),10)=0 Click the Format button On the Borders tab, add a light grey bottom border Click OK, click OK badfastfan wrote: How can I set up the procedure (formatting, macro, whatever) to place a gridline every ten rows on my spreadsheets? Or, how can I get it to put a gridline at every TOTAL line, when I apply subtotals? I have EXCEL 97. -- Debra Dalgleish Contextures http://www.contextures.com/tiptech.html |
#8
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Debra, As usual, a great solution without creating file bloat.
-- Don Guillett SalesAid Software "Debra Dalgleish" wrote in message ... You could add the gridlines with conditional formatting: Turn off the gridlines (ToolsOptions, View tab) Select all the cells on the worksheet Choose FormatConditional Formatting From the first dropdown, choose Formula Is In the formula box, type: =MOD(ROW(),10)=0 Click the Format button On the Borders tab, add a light grey bottom border Click OK, click OK badfastfan wrote: How can I set up the procedure (formatting, macro, whatever) to place a gridline every ten rows on my spreadsheets? Or, how can I get it to put a gridline at every TOTAL line, when I apply subtotals? I have EXCEL 97. -- Debra Dalgleish Contextures http://www.contextures.com/tiptech.html |
#9
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Thanks Don!
Don Guillett wrote: Debra, As usual, a great solution without creating file bloat. -- Debra Dalgleish Contextures http://www.contextures.com/tiptech.html |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
The increase number of rows in Excel | Excel Discussion (Misc queries) | |||
Rows & Columns in Excel | Excel Worksheet Functions | |||
TRYING TO SET UP EXCEL SPREADSHEET ON MY COMPUTER | New Users to Excel | |||
Excel Range Value issue (Excel 97 Vs Excel 2003) | Excel Discussion (Misc queries) | |||
Can Excel "slide up" rows with content thru empty rows to condense | Excel Worksheet Functions |