text boxes. Using your tri-state, the value would be Nothing and thus would
not work to describe the background color you really wanted. In your example
background and 1pt size... it works, but it's not as elegant as it could be.
"Bruce Johnson [MSFT]" <brucejoh@online.microsoft.com> wrote in message
news:e5e2A7#eEHA.2440@tk2msftngp13.phx.gbl...
> Thank your for your comments. Glad the report worked out for you.
>
> Your first issue is a known issue and will be addressed sometime in the
> future by exposing the group number.
>
> Your tri state can be achieved via an expression by setting the value to
> =iif(condition, "text", Nothing).
>
> Bruce
>
> --
> Bruce Johnson [MSFT]
> Microsoft SQL Server Reporting Services
>
> This posting is provided "AS IS" with no warranties, and confers no
rights.
>
>
> "Michael Carr" <mcarr@umich.edu> wrote in message
> news:ulEUkF1eEHA.1424@tk2msftngp13.phx.gbl...
> > Bruce,
> >
> > Thanks a lot, that works really well!!
> >
> > It would be nice if I could get at the ReportItem.Style.BackgroundColor
> > directly rather than relying on a hidden ReportItem.Value ... then I
could
> > implement the necessary computations on the row header's BackgroundColor
> and
> > then just reference that property from the cells in the matrix. I see
from
> a
> > little poking around with Reflector that I can't currently get at that
> value
> > through ReportItem ... :)
> >
> > While I'm on the subject ... how about a tri-state for textbox
visibility
> > that will "Show All", "Hide Text", and "Hide All". There are many
> instances
> > (such as this one, for example) where I'd like to hide the text only and
> > allow the styles to come through.
> >
> > Thanks,
> > Michael Carr
> >
> > "Bruce Johnson [MSFT]" <brucejoh@online.microsoft.com> wrote in message
> > news:#naBhezeEHA.3428@TK2MSFTNGP11.phx.gbl...
> > > See the sample report at the end of this posting.
> > >
> > > --
> > > Bruce Johnson [MSFT]
> > > Microsoft SQL Server Reporting Services
> > >
> > > This posting is provided "AS IS" with no warranties, and confers no
> > rights.
> > >
> > >
> > > "Michael Carr" <mcarr@umich.edu> wrote in message
> > > news:eim57KzeEHA.3476@tk2msftngp13.phx.gbl...
> > > > Is there a way to do alternating line shading in a matrix where not
> > every
> > > > cell contains data? RowNumber isn't consistent in this case because
it
> > > only
> > > > counts cells that contain data.
> > > >
> > > > Michael Carr
> > > >
> > > >
> > >
> > > MatrixGreenbar.rdl
> > >
> > > <?xml version="1.0" encoding="utf-8"?>
> > > <Report
> > >
> >
>
xmlns="
http://schemas.microsoft.com/sqlserver/reporting/2003/10/reportdefini > > > tion"
> > >
> >
>
xmlns:rd="
http://schemas.microsoft.com/SQLServer/reporting/reportdesigner"> > > > <RightMargin>1in</RightMargin>
> > > <Body>
> > > <ReportItems>
> > > <Matrix Name="matrix1">
> > > <Corner>
> > > <ReportItems>
> > > <Textbox Name="textbox1">
> > > <Style>
> > > <BorderStyle>
> > > <Default>Solid</Default>
> > > </BorderStyle>
> > > <PaddingLeft>2pt</PaddingLeft>
> > > <PaddingBottom>2pt</PaddingBottom>
> > > <PaddingTop>2pt</PaddingTop>
> > > <PaddingRight>2pt</PaddingRight>
> > > </Style>
> > > <ZIndex>4</ZIndex>
> > > <rd:DefaultName>textbox1</rd:DefaultName>
> > > <CanGrow>true</CanGrow>
> > > <Value />
> > > </Textbox>
> > > </ReportItems>
> > > </Corner>
> > > <Height>0.5in</Height>
> > > <Style />
> > > <MatrixRows>
> > > <MatrixRow>
> > > <MatrixCells>
> > > <MatrixCell>
> > > <ReportItems>
> > > <Textbox Name="Qty">
> > > <Style>
> > > <BorderStyle>
> > > <Default>Solid</Default>
> > > </BorderStyle>
> > > <PaddingLeft>2pt</PaddingLeft>
> > >
> > > <BackgroundColor>=ReportItems!Color.Value</BackgroundColor>
> > > <TextAlign>Right</TextAlign>
> > > <PaddingBottom>2pt</PaddingBottom>
> > > <PaddingTop>2pt</PaddingTop>
> > > <PaddingRight>2pt</PaddingRight>
> > > </Style>
> > > <rd:DefaultName>Qty</rd:DefaultName>
> > > <CanGrow>true</CanGrow>
> > > <Value>=Sum(Fields!Qty.Value)</Value>
> > > </Textbox>
> > > </ReportItems>
> > > </MatrixCell>
> > > </MatrixCells>
> > > <Height>0.25in</Height>
> > > </MatrixRow>
> > > </MatrixRows>
> > > <MatrixColumns>
> > > <MatrixColumn>
> > > <Width>0.875in</Width>
> > > </MatrixColumn>
> > > </MatrixColumns>
> > > <DataSetName>DataSet1</DataSetName>
> > > <ColumnGroupings>
> > > <ColumnGrouping>
> > > <DynamicColumns>
> > > <Grouping Name="Category">
> > > <GroupExpressions>
> > >
> > > <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
> > > </GroupExpressions>
> > > </Grouping>
> > > <ReportItems>
> > > <Textbox Name="CategoryName">
> > > <Style>
> > > <BorderStyle>
> > > <Default>Solid</Default>
> > > </BorderStyle>
> > > <PaddingLeft>2pt</PaddingLeft>
> > > <TextAlign>Right</TextAlign>
> > > <PaddingBottom>2pt</PaddingBottom>
> > > <PaddingTop>2pt</PaddingTop>
> > > <PaddingRight>2pt</PaddingRight>
> > > </Style>
> > > <ZIndex>3</ZIndex>
> > > <rd:DefaultName>CategoryName</rd:DefaultName>
> > > <CanGrow>true</CanGrow>
> > > <Value>=Fields!CategoryName.Value</Value>
> > > </Textbox>
> > > </ReportItems>
> > > </DynamicColumns>
> > > <Height>0.25in</Height>
> > > </ColumnGrouping>
> > > </ColumnGroupings>
> > > <Width>2in</Width>
> > > <Top>0.125in</Top>
> > > <Left>0.125in</Left>