• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 7276
  • Last Modified:

Crystal Report - Display records horizontal

Hello,

I've an SQL table that has the following fields:

Date
ID
Clategory
Points
Name

I would like to build a report to show the records for a specif date (each date can have the maximum of 6 records) in an horizontal way, something like the image bellow. So each big rectangle is a record with the 4 fields. The number of records can vary from 1 to 6.

Any ideas on how to acomplish this task or what is the best way to do this?


image1.jpg
0
jppinto
Asked:
jppinto
  • 6
  • 2
  • 2
  • +2
3 Solutions
 
wykabryanCommented:
so each box represents a date?
0
 
LinInDenverCommented:
have you played around with "Format with Multiple Columns"?

Create one box in your detail section. When you view the report, it should show all 4-6 lines vertically.

To make them horizontal, try the following.

Right click on your DETAIL section and  choose Section Expert. Check the box for Format with Multiple Columns. This should add a LAYOUT tab, where you can specify the width of each column (i.e.: your boxes). Here are a couple of screenshots.

My example has the Layout set to 3.000 inches. For yours, I think you might want 1.0 or 1.5 inches to make sure up to 6 display on a letter size portrait/landscape page design.

This means your initial box needs to be small than 1.0 or 1.5 inches.

I hope this helps
multiple-columns-crystal.pdf
0
 
jppintoAuthor Commented:
each box represents a record but instead of displaying row by row, I would like to display them on the same row!
0
Cloud Class® Course: Microsoft Windows 7 Basic

This introductory course to Windows 7 environment will teach you about working with the Windows operating system. You will learn about basic functions including start menu; the desktop; managing files, folders, and libraries.

 
LinInDenverCommented:
jppinto please give my suggestion a try, I think it might do the trick for you.
0
 
jppintoAuthor Commented:
OK, sorry but I didn't had the change yet to look at your proposal with attention, I'm going to see now and will report on a few minutes
0
 
jppintoAuthor Commented:
You solution looks good. I'm not able to test this on the live data, only on a test project. Let me try this tomorrow at the company to see if it works and I will post back here on the next 24 hours or so. Sorry for the delay. I won't forget to give you the feedback...

Thanks,

jppinto
0
 
Jorge PaulinoIT Pro/DeveloperCommented:
Since you have only 6 columns(maximum) you can format the report and then pass discrete parameters to Crystal Reports from the code.
Check this example http://www.codeproject.com/KB/vb/CrystalContrl.aspx 
 
0
 
jppintoAuthor Commented:
Sorry, didn't had the change to test neither of the solutions. Just posting to say that I didn't forgot this...

jppinto
0
 
Jorge PaulinoIT Pro/DeveloperCommented:
Why don't you use Microsoft Reporting Services and define that as parameters? You can only do that in Crystal Reports, but I like it more.
Check this article http://www.codeproject.com/KB/vb/MicrosoftReports.aspx
0
 
jppintoAuthor Commented:
I was not able to complete this using Crystal Reports but I've tryed Microsoft Reporting Services, like mentioned by jpaulino, and It worked well. Thanks to all.
0
 
jppintoAuthor Commented:
I used Microsoft Reporting Services and found this article on how to do it:

http://blogs.msdn.com/chrishays/

Look for "Horizontal Tables" part.

jppinto
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

  • 6
  • 2
  • 2
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now