.NETGURU
Declaring the report
Messages   Related Types
This message was discovered on ASPFriends.com 'ngfx-crystal' list.


=?iso-8859-1?Q?Jonathan_Hjertstr=F6m?=
Hi,

Does anyone know how to declare a report class in a Sub?

What I want to do is to have a generic report function that can take the =
report class as an argument and then declare it in the function.
Now for one report I have it like this:

Dim oRpt As SummaryCaseLoadperJudge =3D New SummaryCaseLoadperJudge()

Where SummaryCaseLoadperJudge is the name of my report. I would like to =
substitute the name with whatever name I set for my function.

I am not using a report viewer. My environment is VS.NET, ASP.NET with =
VB.
I have done similar things for a dropdown list but I don't know what I =
should declare my argument as.

Thanks for any help!

**************************************************************
Jonathan Hjertstr=F6m,
Software Developer, K2-Informatics (U) Ltd.
32, Kanjokya Street, Kololo, P.O. Box 8628,
Kampala, Uganda
tel. +256 41 532 865 / 871 / 873
fax. +256 41 532 910
http://www.k2informatics.com
**************************************************************

Reply to this message...
 
    
Johnson, Peter
I'm not clear on what you're wanting to do, but I'll guess...

One thing we've got is a standalone report testing page that runs one =
of
several reports and exports a PDF. The code (forgive my VB.NET, I'm a =
C#
guy) looks something like this:

Import CrystalDecisions.CrystalReports.Engine

Dim oRpt As ReportClass
Switch Case myString
    Case "Judge":
        oRpt =3D New SummaryCaseLoadperJudge()
    Case "Jury":
        oRpt =3D New SummaryCaseLoadperJury()
    Case "Executioner":
        oRpt =3D New SummaryCaseLoadperExecutioner()
End Switch

If you look at each report's "code-behind" e.g. =
SummaryCaseLoadperJudge.cs,
you'll see they all inherit from ReportClass.

Is this what you meant? If not, it might help me if you explained what
you've done with a dropdown list that you're wanting to do here.

--Peter

[Original message clipped]


**********************************************
This e-mail and any attachments may be confidential or legally =
privileged.
If you received this message in error or are not the intended =
recipient, you
should destroy the e-mail message and any attachments or copies, and =
you are
prohibited from retaining, distributing disclosing or using any =
information
contained herein. Please inform us of the erroneous delivery by return
e-mail. Thank you for your cooperation.
**********************************************

ec03/04

Reply to this message...
 
    
=?iso-8859-1?Q?Jonathan_Hjertstr=F6m?=
Hello Peter,

It something like that I looked for. It seems to work fine. I have to do =
some more testing but so far so good.

I just needed to replace the Switch command with Select.

Thanks a lot!!!!

Best regards,

Jonathan Hjertstr=F6m

-----Original Message-----
From: Johnson, Peter [mailto:Click here to reveal e-mail address]=20
Sent: den 18 juni 2002 15:06
To: ngfx-crystal
Subject: [ngfx-crystal] RE: Declaring the report

I'm not clear on what you're wanting to do, but I'll guess...

One thing we've got is a standalone report testing page that runs one of
several reports and exports a PDF. The code (forgive my VB.NET, I'm a C#
guy) looks something like this:

Import CrystalDecisions.CrystalReports.Engine

Dim oRpt As ReportClass
Switch Case myString
    Case "Judge":
        oRpt =3D New SummaryCaseLoadperJudge()
    Case "Jury":
        oRpt =3D New SummaryCaseLoadperJury()
    Case "Executioner":
        oRpt =3D New SummaryCaseLoadperExecutioner()
End Switch

If you look at each report's "code-behind" e.g. =
SummaryCaseLoadperJudge.cs,
you'll see they all inherit from ReportClass.

Is this what you meant? If not, it might help me if you explained what
you've done with a dropdown list that you're wanting to do here.

--Peter

[Original message clipped]


**********************************************
This e-mail and any attachments may be confidential or legally =
privileged.
If you received this message in error or are not the intended recipient, =
you
should destroy the e-mail message and any attachments or copies, and you =
are
prohibited from retaining, distributing disclosing or using any =
information
contained herein. Please inform us of the erroneous delivery by return
e-mail. Thank you for your cooperation.
**********************************************

ec03/04

| [ngfx-crystal] member Click here to reveal e-mail address =3D YOUR ID
| http://www.aspfriends.com/aspfriends/ngfx-crystal.asp =3D JOIN/QUIT

Reply to this message...
 
 




ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
Ad


Need Dot Net Interview Questions?
Ask ExamGuru, Inc. for advice and help on Passing .Net Interviews
.Net Projects
Best-of-breed application framework for .NET projects, developed by ExamGuru, Inc. and ExamGuru IT
Free .net Help
Commission ExamGuru, Inc. and his team for your next bespoke software project
FogBUGZ
The only bug tracking system carefully crafted with one goal in mind: helping teams create great software.
Awesome Tools
If you don't know about these, you're missing out... IT Certification Questions
IT Interview Questions
Free Oracle 10g Training
MCSE Boortcamp
Cisco Study Guides
Cheap Study Guides
Exact Questions
Dot Net Interview Questions
Oracle OCP
Cheap Travel
Designer Perfumes - Wholesale Prices
Free Programming Tutorials
 
ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
 Copyright © ExamGuru, Inc. 2001-2006
Contact Us - Terms of Use - Privacy Policy - www.dot-net-guru.com - www.examguru.net - www.oraclesource.net - www.itinterviews.net - www.examguru.net/ITCertification