PC Review


Reply
Thread Tools Rate Thread

Does crystal reports always needs a database ?

 
 
Rodo
Guest
Posts: n/a
 
      23rd Apr 2007
Hi all,

I'm new to this whole thing. I have a bunch of text files that are created
by a software at work that keeps info one of our products. Each unit being
calibrated gets a "record" (track by serial number) which is a text file
with data. The data is almost all the same format. There is header info
about the customer, then some more specs about the product then between 5 to
14 rows of calibration data.

The software that controls the whole thing is ancient. I don't want to touch
it. It writes this text file to the network for every unit that ships out. I
need to look at the files whenever I need to. I was hoping to have a windows
form to open the text file and somehow have the report template in a crystal
report file. The windows form coud display the data and print it if required
but it looks like I need to have the data in a database... which I do not.

Is this even possible ?


Thanks in advance.


 
Reply With Quote
 
 
 
 
Alberto Poblacion
Guest
Posts: n/a
 
      23rd Apr 2007
"Rodo" <(E-Mail Removed)> wrote in message
news:syXWh.1049$nR1.209@trnddc06...
>[...] I was hoping to have a windows form to open the text file and somehow
>have the report template in a crystal report file. The windows form coud
>display the data and print it if required but it looks like I need to have
>the data in a database... which I do not.


Crystal Reports can take the data from inside a DataSet that you provide
via the SetDataSource method of the ReportDocument. You can build the
dataset in memory with your own code, without using a database at all.

 
Reply With Quote
 
Manu
Guest
Posts: n/a
 
      23rd Apr 2007
On Apr 23, 10:33 am, "Rodo" <dsp1...@yahoo.com> wrote:
> Hi all,
>
> I'm new to this whole thing. I have a bunch of text files that are created
> by a software at work that keeps info one of our products. Each unit being
> calibrated gets a "record" (track by serial number) which is a text file
> with data. The data is almost all the same format. There is header info
> about the customer, then some more specs about the product then between 5 to
> 14 rows of calibration data.
>
> The software that controls the whole thing is ancient. I don't want to touch
> it. It writes this text file to the network for every unit that ships out. I
> need to look at the files whenever I need to. I was hoping to have a windows
> form to open the text file and somehow have the report template in a crystal
> report file. The windows form coud display the data and print it if required
> but it looks like I need to have the data in a database... which I do not.
>
> Is this even possible ?
>
> Thanks in advance.


Hi!

Use you own custom code to populate a dataset and then pass it to
Crystal Reports ReportDocument Object using SetDataSource Method.

The easiest way is to Design your DataSet using DataSet Designer. Then
Create Your Report using Crystal Reports and specify the Data Source
for the report as ADO.net DataSet.

Then at runtime Populate that Data Set with Data using your custom
code and then pass it on the Crystal Report using SetDataSource
Method.

If you need any further info fee free to contact me

Bye
Manu Singhal
MCP
(E-Mail Removed)



 
Reply With Quote
 
sloan
Guest
Posts: n/a
 
      23rd Apr 2007


I would recommend going ALL your CRs using a dataset.

CR is basically a "presentation layer", and if you seperate your code to
create a datasource (dataset) from the presentation layer, you will find
maintenance much easier.

CR talking directly to your db is "rapid development", which isn't always
"the best development".

You will also have the ability to switch to another report tool (Active
Reports?) in the future if you go with the DataSet model.




"Rodo" <(E-Mail Removed)> wrote in message
news:syXWh.1049$nR1.209@trnddc06...
> Hi all,
>
> I'm new to this whole thing. I have a bunch of text files that are created
> by a software at work that keeps info one of our products. Each unit being
> calibrated gets a "record" (track by serial number) which is a text file
> with data. The data is almost all the same format. There is header info
> about the customer, then some more specs about the product then between 5

to
> 14 rows of calibration data.
>
> The software that controls the whole thing is ancient. I don't want to

touch
> it. It writes this text file to the network for every unit that ships out.

I
> need to look at the files whenever I need to. I was hoping to have a

windows
> form to open the text file and somehow have the report template in a

crystal
> report file. The windows form coud display the data and print it if

required
> but it looks like I need to have the data in a database... which I do not.
>
> Is this even possible ?
>
>
> Thanks in advance.
>
>



 
Reply With Quote
 
Bruce Wood
Guest
Posts: n/a
 
      23rd Apr 2007
On Apr 22, 10:33 pm, "Rodo" <dsp1...@yahoo.com> wrote:
> Hi all,
>
> I'm new to this whole thing. I have a bunch of text files that are created
> by a software at work that keeps info one of our products. Each unit being
> calibrated gets a "record" (track by serial number) which is a text file
> with data. The data is almost all the same format. There is header info
> about the customer, then some more specs about the product then between 5 to
> 14 rows of calibration data.
>
> The software that controls the whole thing is ancient. I don't want to touch
> it. It writes this text file to the network for every unit that ships out. I
> need to look at the files whenever I need to. I was hoping to have a windows
> form to open the text file and somehow have the report template in a crystal
> report file. The windows form coud display the data and print it if required
> but it looks like I need to have the data in a database... which I do not.


I'll echo what the others have said here: you can put the data into a
DataSet and pass it to Crystal. We do that here exclusively. (Note
that Crystal has some quirks when designing from an ADO.NET data
set... some bits of the Crystal Reports Designer that deal with this
are buggy and have been for several versions. It's not a show-stopper,
just annoying.)

That said, you may want to do yourself a favour and put the data in a
database anyway, just because it will be so much more accessible for
other purposes. Whether you then decide to use Crystal to pull from
the database directly, or still feed it via a DataSet in your program,
well that's up to you.

You can write Windows services in C#, and C# has a FileSystemWatcher
class that will alert you when new files are created in a directory.
Even if you have multiple directories, you could write a small Windows
service that monitors them all and, when a new file is created by your
ancient application, parses the file and puts the information into a
database in whatever format you choose. You could then write all new
software to read the database. There would be only a short delay
between the file being created and the database being updated (a delay
that you could determine and tune in your application).

I believe that you could even cope with files being updated and, with
some cleverness, files being deleted, although I don't know whether
your ancient application does these things.

All of this doesn't necessarily help you with your reporting issue.
It's more of a springboard for later development, all without touching
the legacy app, as you said.

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Crystal Reports Does Not Display BLOB Field Correctly in IBlobField Control Using Crystal Reports for VS.NET 2003 Jeff Microsoft Dot NET 0 4th May 2006 09:21 PM
Database Login for Crystal reports Murali via DotNetMonster.com Microsoft VB .NET 12 11th Oct 2005 12:17 PM
Crystal Reports/SQL Database JoeK Microsoft VB .NET 0 16th Mar 2005 04:28 PM
Crystal Reports - Database Login? Chris Ashley Microsoft VB .NET 1 12th Nov 2004 04:35 PM
Crystal Reports database log in lilush Microsoft Dot NET 0 21st Feb 2004 10:49 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 11:56 PM.