?
Solved

Help with seeing vertical and horizontal lines of a table and setting background and text colors of eve and odd rows

Posted on 2012-04-02
8
Medium Priority
?
367 Views
Last Modified: 2012-04-03
Hello,

How do  I see the  vertical and horizontal lines of a table and How do I set background and text colors of even and odd rows in my report?

Thanks,

victor
0
Comment
Question by:vcharles
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
8 Comments
 
LVL 37

Accepted Solution

by:
ValentinoV earned 2000 total points
ID: 37799483
"How do  I see the  vertical and horizontal lines of a table "

Do you mean when the report is rendered?  You can use the Border properties to set the cell borders.

"How do I set background and text colors of even and odd rows in my report?"

For alternating coloring you can use the RowNumber function in an expression.  The following would be an example of a possible expression on the BackgroundColor property of a textbox (table cell):

=IIf(RowNumber("YourDataSet") Mod 2 = 0, "Blue", "Transparent")

More info: http://msdn.microsoft.com/en-us/library/ms159225(v=sql.100).aspx
0
 

Author Comment

by:vcharles
ID: 37799513
Yes, I mean when they see the report, I need to be able to see how the colums are separated.
I am fairly new at this, will look for the borders property and set it as you suggested.
 where do I enter =IIf(RowNumber("YourDataSet") Mod 2 = 0, "Blue", "Transparent")

Thanks,
0
 
LVL 37

Expert Comment

by:ValentinoV
ID: 37799550
The expression goes into the BackgroundColor property which you'll find as one of the properties of a textbox (i.e. cell in a tablix).

BTW: are you using the SSRS designer or .NET code (I noticed you've got the ASP.NET topic in your question as well as SSRS).
0
Get real performance insights from real users

Key features:
- Total Pages Views and Load times
- Top Pages Viewed and Load Times
- Real Time Site Page Build Performance
- Users’ Browser and Platform Performance
- Geographic User Breakdown
- And more

 

Author Comment

by:vcharles
ID: 37799753
I am using using SSRS, but thought they also use the same type of report (RDLC) with SQL.
I have another question, perhaps you can help me answer it on the same post or I can open another post.

Previously my data was in a table format with multiple records displayed, now I need to display one record per page, how do I modify my code.

For example:

Table Format:

Country   Address Zip   Item
BEL            xyz        112  Car
CAN           xyz        112  Car
DEU           xyz        112  Car
FRA           xyz         112  Car

Now I need

Record 1 of 4

Country    BEL
Address    xyz
Zip            112
Item         Car

Record 2 of 4

Country    CAN
Address    xyz
Zip            112
Item         Car



Record 3 of 4

Country    DEU
Address    xyz
Zip            112
Item         Car



Record 4 of 4

Country    FRA
Address    xyz
Zip            112
Item         Car


Below is the code I am currently using to display the data using a datatable:


 Dim FilteredDT As DataTable
 Dim DV As New DataView(dt, SearchCriteria, Nothing, DataViewRowState.CurrentRows)
        FilteredDT = DV.ToTable
 Dim reportDataSource As New Microsoft.Reporting.WinForms.ReportDataSource()
        reportDataSource.Name = "MyDataSet_Links"
        reportDataSource.Value = FilteredDT
        ReportViewer2.LocalReport.DataSources.Clear()
        ReportViewer2.LocalReport.DataSources.Add(reportDataSource)
        ReportViewer2.LocalReport.Refresh()
        ReportViewer2.RefreshReport()

Thanks,

Victor
0
 
LVL 7

Expert Comment

by:dhawalseth
ID: 37800018
0
 

Author Comment

by:vcharles
ID: 37800139
Thanks!
0
 
LVL 37

Expert Comment

by:ValentinoV
ID: 37800148
If you have other questions (such as the one in comment 37799753) it's better to open other questions instead of putting them in an already open one...  That's more in line with the Problem/Solution philosophy.

You'll also attract more experts looking at the problem in question because they can then focus on just that one particular issue.
0
 

Author Comment

by:vcharles
ID: 37800166
Got it. Thanks.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Written by Valentino Vranken. Introduction: The first step of creating a SQL Server Reporting Services (SSRS) report involves setting up a connection to the data source and programming a dataset to retrieve data from that data source.  The data…
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question