turn off warning "not CLS-compliant"



I get this error over and over: Return type of function 'ReportHeaderSection1' is not CLS-compliant

is there a way to turn this warning off?

What does it mean?
LVL 4
brokeMyLegBikingAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Bob LearnedCommented:
What is this in relation to?  Crystal Reports?  Where is 'ReportHeaderSection1' defined?

Bob
0
brokeMyLegBikingAuthor Commented:
I get this warning for Crystal Reports and also for some ReportViewer objects. Mostly for Crystal reports.

Does Crystal Reports not conform to the CLS standard?
0
Bob LearnedCommented:
1) Crystal Reports version?

2) http://msdn2.microsoft.com/en-US/library/x97t56y6.aspx

3) .NET version?

Bob
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

brokeMyLegBikingAuthor Commented:
ok, that is a good explination, unfortunately, in the project properties, there is no way to turn off this particular warning.

I have 9 conditions on the compile tab of the project properties page, but none of them is CLS related.
0
Bob LearnedCommented:
That didn't quite answer all the questions.  If you can give me more information, I can ask my Crystal Reports friends if they have seen that exception.

Bob
0
brokeMyLegBikingAuthor Commented:
crystal reports 10

2 does addresses the issue, yes, that was helpful.

3) .net 2.0
0
Bob LearnedCommented:
1) Is this a single report giving you this error or every report?

If it's a single report you can probably open the [reportname].vb module that Visual Studio creates (it's just a class wrapper for the report) and go to the ReportHeaderSection1 Property and debug further.  In .Net 1.1 it should be returning a value of the type: CrystalDecisions.CrystalReports.Engine.Section  - I assume it hasn't changed in .Net 2.0 but I haven't verified that.

I've seen the CrystalDecisions.CrystalReports.Engine reference lose its binding in Visual Studio on occassion, for reasons I cannot explain.  Removing the reference from my project and re-adding it again seems to correct the binding and eliminates the compile errors that had been found.  Since that's the dll that contains the return type for the section in question this may be worth a few seconds to attempt.

2) Can you share a code snippet on your process to load the Crystal report?

Bob
0
Bob LearnedCommented:
I didn't notice that you accepted my comment above.  Did you find a solution?

Bob
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.

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.