Solved

"Value does not fall within the expected range" with long CR parameter

Posted on 2008-10-30
8
1,852 Views
Last Modified: 2013-11-26
Using Crystal Reports for .NET with Visual Studio .NET 2003, I'm passing a string parameter that is sometimes more than 254 characters. When it is, CR fails with the error: "Value does not fall within the expected range"

I've seen both here and on CR's web site that this is a known problem. However, I'm having difficulty finding a fix for it, in part because the support site has been totally rewritten since SAP's purchase of BusinessObjects earlier this year. I've downloaded some hotfix files, and was able to install a couple of them (crnet10win_en.zip and crnet11win_en.zip). However, while the version number of the files in C:\Program Files\Common Files\Crystal Decisions\1.1\Managed is now 9.1.9800.x (varies for different DLLs), the version number displayed in the references both for my project and in VS's list of .NET components still shows the original 9.1.5000.0. I've deleted the references from my project and readded them directly from the Managed files, but the version number doesn't change.

And according to other messages here (such as http://www.experts-exchange.com/Database/Reporting_/Crystal_Reports/Q_21692476.html), I need a version number of 9.2.9500.1 to get the fix anyway. However, if I try to run the update cr90devwin_en.zip, it fails when trying to update registry values, which I believe indicates a version mismatch (.NET isn't the same as CR v9).

Any ideas on how to resolve this, short of moving to a newer version of VS or buying CR? Unfortunately, splitting up the data into multiple pieces doesn't resolve my problem, because the parameter could be lengthy (it's a list of files being used, with full path information) and I don't know how much space to allow.
0
Comment
Question by:ElrondCT
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
8 Comments
 
LVL 101

Expert Comment

by:mlmcc
ID: 22851740
You are correct, the .Net version isn't the same as the full version.

Check here for the service packs and hot fixes.
https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/bobj_download/main.htm

You may have to contact SAP/BO to get what you need since I didn't see any for the older versions of Crystal.Net

mlmcc
0
 
LVL 20

Author Comment

by:ElrondCT
ID: 22877006
I've gotten all the packs and hotfixes from that location that I can, but it doesn't resolve the situation.

The only way I see to contact SAP/BO for further assistance is by paying for a support incident at $195. If I'm going to pay that much, I might as well pay a few dollars more and get a full-fledged copy of CR. Is there another way to get assistance at lower (or no) cost?
0
 
LVL 101

Accepted Solution

by:
mlmcc earned 500 total points
ID: 22890384
Only at sites like this.  The new SAP site does have a developer forum you might ask there.

mlmcc
0
Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

 
LVL 20

Author Comment

by:ElrondCT
ID: 22961804
I've posted a question in SAP's forums, and have gotten no response. I'm not sure if that means no one's paying attention, or there's nothing to offer. Looks like I'll have to figure out some workaround. Since I only need the parameter to print out at one place in the report, I thought about using

            CType(rptOut.ReportDefinition.ReportObjects(strTextObject), _
                CrystalDecisions.CrystalReports.Engine.TextObject).Text = strOutput

to store the value into a text object, but I'm finding that the line breaks I want (between each file name, so each file is on a separate line) are getting converted into spaces, so the text is just running across the line. Any suggestions for an alternative?
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 22962618
Build your string like

strOutput = "Some FileName" & chr(13) & "Next FileName" & chr(13) & "thirdFileName"

mlmcc
0
 
LVL 20

Author Comment

by:ElrondCT
ID: 22963012
I was already putting chr(13) & chr(10) between each line. When I take out the chr(10), I don't even get a blank space between the file names; they just run on. I wondered if the CanGrow property on the text field could be involved, but setting that False gives the same results.
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 22963316
Is this in the viewer or are you exporting?

Why are you doing the CTYPE?  That may be converting them to spaces.

mlmcc
0
 
LVL 20

Author Comment

by:ElrondCT
ID: 22986847
Sorry, I tried to post a response but it looks like it didn't take. The CType is needed because not all ReportObjects have a Text property, so the CType tells VB what kind of ReportObject I'm working with so it doesn't give an error when compiling.

I found that I posted my question on the wrong forum at SAP; there's a specific forum for CR on .NET (which makes a lot of sense), but it wasn't linked to from the CR for .NET portal page. For anyone interested, the proper forum page is https://forums.sdn.sap.com/forum.jspa?forumID=313&start=0

Because it was posted in the wrong place, I didn't get any help. It was moved, but because the post was several days old, it's now buried, so I'm going to repost. But I'll close out here.
0

Featured Post

Linux Academy Android App Now Supports Chromecast

We have some fantastic news for our Android fans. We’re so excited to announce that the Linux Academy Android app is now available with Chromecast support. That’s right – simply download the latest update of the Linux Academy App and start casting your favorite course videos!

Question has a verified solution.

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

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…

631 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