Index was out of range.

Technical support for Spire.DataExport

Moderators: iceblue support, DataExport, Manager

Index was out of range.

Postby LijuanWu_Spire » Thu Aug 30, 2012 3:35 pm

Basically I was create a pdf file combined data from database and append pdf files from .net 4.0 web application. The code worked perfectly in my DEV enrovoment. However I got the following error when moving to QA. First I check my database to see if it's data issue. All the data from dev DB and QA DB is same. The environment for hosting application is same. The only difference is MS office is installed on DEV. Not on QA. I didn’t install spire office on QA environment Just included all .dll files in bin folder. Do you think this is the reasone? I tried just hard code and write a hello world out. Not getting data from DB. Still got the error. Again DEV works and QA doesn’t work. Please give some advises.

Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index]
System.ThrowHelper.ThrowArgumentOutOfRangeException() +72
System.Collections.Generic.List`1.System.Collections.IList.get_Item(Int32 index) +18
Spire.Pdf.Tables.PdfColumnCollection.get_Item(Int32 index) +13
PrintApplication.DrawApplicant(PdfSection section, PdfMargins margin) +8300
PrintApplication.butViewPDF_Click(Object sender, EventArgs e) +282
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +118
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +112
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5563

Thanks!
LijuanWu_Spire
 
Posts: 14
Joined: Tue Aug 07, 2012 6:30 pm

Re: Index was out of range.

Postby amy.zhao » Fri Aug 31, 2012 10:20 am

Hi LijuanWu_Spire,

Thanks for your inquiry.

We are so sorry for this inconvenience caused by us.
No install Spire.Office is not the reason, copying all dll files should also work fine.
This problem is too strange to find the reason without other information. Would you please provide us:
1. The environment of your QA, for example: Windows 2008 x64? the version of IIS..
2. You HelloWorld test application.
3. All the assembly files of our product and their version
And then we will try to reproduce your problem and fix it as soon as possible.

Best wishes,
Amy
e-iceblue support
User avatar
amy.zhao
 
Posts: 2195
Joined: Wed Jun 27, 2012 8:50 am

Re: Index was out of range.

Postby LijuanWu_Spire » Wed Sep 05, 2012 7:52 pm

thanks. I found out what is the issue. It's not related to Spire office. One storage procedure was missing on QA DB.
LijuanWu_Spire
 
Posts: 14
Joined: Tue Aug 07, 2012 6:30 pm


Return to Spire.DataExport

Who is online

Users browsing this forum: No registered users and 0 guests