Solved

How to design this report using Crystal Report .Net 2008?

Posted on 2011-02-15
12
544 Views
Last Modified: 2012-05-11
Hello,

I want to design a report that depicts machine stop times as shown in attached picture. The database table stores stop times and start times for each machine error. The report should depicts each hour of the shift as 60 small squares and shadow minutes of machine failure.

I want to do this very efficiently both the queries and report design and I use SQL server 2008.

Thanks
machines-stop-times-report.PNG
0
Comment
Question by:smetechit
  • 7
  • 5
12 Comments
 
LVL 100

Expert Comment

by:mlmcc
ID: 34903331
As far as I know there are no chart types that will do what you want.

What data do you have in the database?
Is it a start datetime and an enddatetime?

The lines will be the nearly impossible part since there is no easy way to draw them.

How many hours might be covered by a report?

mlmcc
0
 

Author Comment

by:smetechit
ID: 34903835
I have 8 hours in the report , i.e 8 lines of squares

The data source is the stop time and start time only.

My idea is to use text boxes or box objects . how to change thier background color using data available in this table.
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 34903864
WOuld something like this be good enough


------------------------------
 | | | | |X|X|X|X|X| | | | |
------------------------------

mlmcc
0
 
LVL 100

Accepted Solution

by:
mlmcc earned 500 total points
ID: 34904062
Take a look at this report.  I have saved the data with it so you can see what it does.

To use it with your data just change the database and Change Field1 and Field2 to your start and stop fields.

mlmcc

DownTimeChart.rpt
0
 

Author Comment

by:smetechit
ID: 34904237
Hi mlmcc,

I could open your report using Crystal Report 10 but can not open with Visual Studio.Net 2008. Can you send me detailed steps to create it in VS.NET 2008. It seems working :)

Thanks
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 34907401
If you can open it in CR10 then just copy the formulas that are being used.
I don't have a workingVS.Net environment to build it in

mlmcc
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:smetechit
ID: 34915627
Hi mlmcc,

I changed data source to reference my database but I can not view the report du to this error "There must be a group that matches this field" - please see attached picture.
group-error.png
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 34919426
The formula causiing the issue

CSTr(Time(GroupName ({Table2.Field1}, "by hour")),"hh:mm") & " - " & CSTr(Time(GroupName ({Table2.Field1}, "by hour")),"hh:59")

Change {Table2.Field1} to the time field you are grouping on

mlmcc
0
 

Author Comment

by:smetechit
ID: 34936139
Hi mlmcc,

Just two questions:
1) How do you make the report caches the data without mdb file existance?
2) What is the purpose of these formula fields: DeclVars, Groupreset, x, CreateString?

Thanks
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 34937830
DeclVars - declares the variables for the report

Groupreset- resets the value of various variables to an initial state otherwise the previous group values get used

x and CreateString - formulas I used for trying an idea.  X printed all the characters 50 per line so I could find the filled box and empty box.  They aren't needed for the report

mlmcc
0
 

Author Comment

by:smetechit
ID: 34938221
I deleted DeclVars and Groupreset and the report still working the same.

There is a small bug in the formula , see the example below

08:50 - 09:10
10:40 - 10:50

renders the report the same as

08:50 - 09:10
09:40 - 09:50

Have you a fix for this?


Thanks
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 34939362
You need the Groupreset formula to reset the string when a new group starts.

It is group on time by hour.

mlmcc
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.

864 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now