Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default No borders/gridlines around some cells

What is the best way to not show any borders or gridlines around some cells
(not the whole sheet)?

For example, when I change the Layout of a Column field in a Pivot Table to
"Show Items in Outline Form," much of the Pivot Table has no black borders
and no grey gridlines around the cells.

When I use VBA to inspect those cells, I see a Borders.Linestyle = 1, and a
Borders.ColorIndex = xlColorIndexNone (-4142). So, the border seems to be a
line with no color, which must cover up the default gridlines.

But I cannot use VBA to set the borders that way. When I set the ColorIndex
to xlColorIndexNone, Excel automatically changes the Linestyle to -4142. So,
rather than getting a line with no color, I get no line (with no color).

Charlie Rowe
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 108
Default No borders/gridlines around some cells

I never fool with this, but can you set the ColorIndex to xlColorIndexNone
and then change the Borders.Linestyle back to 1?

--- "Charlie Rowe" wrote:
What is the best way to not show any borders or gridlines around some cells
(not the whole sheet)?

For example, when I change the Layout of a Column field in a Pivot Table to
"Show Items in Outline Form," much of the Pivot Table has no black borders
and no grey gridlines around the cells.

When I use VBA to inspect those cells, I see a Borders.Linestyle = 1, and a
Borders.ColorIndex = xlColorIndexNone (-4142). So, the border seems to be a
line with no color, which must cover up the default gridlines.

But I cannot use VBA to set the borders that way. When I set the ColorIndex
to xlColorIndexNone, Excel automatically changes the Linestyle to -4142. So,
rather than getting a line with no color, I get no line (with no color).

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default No borders/gridlines around some cells

No, when I set the Color to None, Excel automatically changes the LineStyle
to None. When I then change the LineStyle to 1, Excel automatically changes
the Color to Automatic (-4105). I cannot get both the LineStyle and the
Color set to None; but the Pivottable can do it.


"Bob Bridges" wrote:

I never fool with this, but can you set the ColorIndex to xlColorIndexNone
and then change the Borders.Linestyle back to 1?

--- "Charlie Rowe" wrote:
What is the best way to not show any borders or gridlines around some cells
(not the whole sheet)?

For example, when I change the Layout of a Column field in a Pivot Table to
"Show Items in Outline Form," much of the Pivot Table has no black borders
and no grey gridlines around the cells.

When I use VBA to inspect those cells, I see a Borders.Linestyle = 1, and a
Borders.ColorIndex = xlColorIndexNone (-4142). So, the border seems to be a
line with no color, which must cover up the default gridlines.

But I cannot use VBA to set the borders that way. When I set the ColorIndex
to xlColorIndexNone, Excel automatically changes the Linestyle to -4142. So,
rather than getting a line with no color, I get no line (with no color).

Reply
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
Borders & Gridlines SargeUSMC Setting up and Configuration of Excel 1 February 24th 11 02:34 AM
Excel 2007 - Gridlines & Borders printing problem toriel_c Excel Discussion (Misc queries) 0 October 2nd 09 03:34 PM
Data in cells with gridlines moves up within the cells. J Osborne Excel Discussion (Misc queries) 0 November 18th 08 06:51 PM
Show gridlines or cell borders on top of a picture sukey51 Excel Discussion (Misc queries) 0 March 24th 07 04:55 AM
Lightened gridlines, now borders are that color now, even though Kendall Setting up and Configuration of Excel 1 August 15th 05 01:08 PM


All times are GMT +1. The time now is 10:16 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"