Question

Error running Inv/ WIP report

  • 13 May 2021
  • 4 replies
  • 103 views

Userlevel 2

We are getting the following error when the WIP report is trying to display in the Crystal Viewer -

 

Error Detail

============

Unexpected end of file has occurred. The following elements are not closed: ReportDataSet. Line 333, position 1.

 

 

Stack Trace

===========

   at System.Xml.XmlTextReaderImpl.Throw(Exception e)

   at System.Xml.XmlTextReaderImpl.Throw(String res, String arg)

   at System.Xml.XmlTextReaderImpl.Throw(Int32 pos, String res, String arg)

   at System.Xml.XmlTextReaderImpl.ThrowUnclosedElements()

   at System.Xml.XmlTextReaderImpl.ParseElementContent()

   at System.Xml.XmlTextReaderImpl.Read()

   at System.Xml.XmlTextReader.Read()

   at System.Xml.XmlReader.ReadEndElement()

   at System.Data.DataSet.ReadEndElement(XmlReader reader)

   at System.Data.DataSet.ReadXSDSchema(XmlReader reader, Boolean denyResolving)

   at System.Data.DataSet.ReadXml(XmlReader reader, Boolean denyResolving)

   at System.Data.DataSet.ReadXml(String fileName)

   at Epicor.Mfg.Lib.Report.EpiCrystalPushRpt.Process(List`1 rptDocList, String dataFile, String rptFile, DataSet dtsData, Session session)

   at Epicor.Mfg.Lib.Report.EpiCrystalViewer.LoadReport(Object state)

 

 

We are doing our first pass for upgrade and this keeps happening.

 


4 replies

Userlevel 3

Hi @daniel-white 

It’s been a while since I used Crystal with Epicor ERP but I believe this error is related to the data definition file. There is a finite length / max string that Crystal can read and I suspect you’ve gone over that limit.

If it’s a customised report, try and remove elements from the RDD you’re not using. In a previous role I had a similar error with a customised Job Traveller, in the end we pulled all the report labels that weren’t in use. 

Have you tried using the std report definition to check for the same error (if you are currently using a custom RDD)?

Alternatively, try the SSRS report. I know this isn’t always possible due to highly customised reports in prior versions of Epicor, 1. it will validate the results and 2. this will ultimately be something that needs to be done as Crystal support is deprecated from the application.

Tim

P.S. The generated data file from Epicor normally completes without issue. I don’t believe there is a limitation/check against the output.

Userlevel 2

HI Tim,

  Thanks for the response. This is the standard O.O.B. Inv/WIP report and you reply about the limit in the crystal report stacks up with what i have read elsewhere.

Unfortunately we do not have SSRS setup in 9.

 

Daniel

Userlevel 4

Dear Daniel, 

 

I recommend opening the XML file in your favorite XML viewer.  You may find it’s nowhere near the character limit for Crystal.  Try comparing it with another XML created for the same report from your working legacy system.

I’ve found the Crystal Reports XML generation modules of E9 (and E10 for that matter) to be very unforgiving when it comes to errors.  Specifically, on an upgrade from 8 to 10, a non-printable character in a comment or description field, terminated the XML abruptly, with the only error being the CR runtime complaining with the same error message you’re describing.

In other cases, we had to look at the legacy system’s custom RDDs compared to the stock (original) ones in the same system, and re-create them using the same deltas off the stock (original) RDDs in the new upgraded system.  You can even take it a step at a time, starting with the working, new RDDs and making one change at a time until you get it working with your customizations.  Remember, you can take a stock (original) report style, duplicate it and make the duplicate a Crystal style.  And in E10, all Crystal reports must be placed in the CustomReports subdirectory.

 

HTH

….Monty.

Monty Wilson

ERP Product Liaison

Epicor Users Group

Monty.Wilson@epicorusers.org

Userlevel 2

Monty,

  I ran the report over a smaller time frame which enabled it to run and looking at the XML for that Line 333 is the line where all the ‘Data’ fields start to be brought in. Example below, line 333 is <Company>

    <Company>
        <RptLanguageID>enu</RptLanguageID>
        <AllowDefaultDoc>true</AllowDefaultDoc>
        <AttachDefaultMechanism>3</AttachDefaultMechanism>
        <BitFlag>0</BitFlag>
        <Company>STI</Company>
        <CurrentFiscalYear>1980</CurrentFiscalYear>
        <EnableFileSys>false</EnableFileSys>
        <EnableSharePoint>false</EnableSharePoint>
        <FiscalCalendarID>CompCal</FiscalCalendarID>
        <Name>Surface Technology Intl Ltd</Name>
        <ReportTypePref>Crystal</ReportTypePref>
        <SysRevID>210470000</SysRevID>
        <SysRowID>df2e5dc5-8674-c1af-e211-c0da1ba21329</SysRowID>
        <TrackPersonalizationChg>false</TrackPersonalizationChg>
        <TrackSysActivity>false</TrackSysActivity>
    </Company>
    <Recon>
        <RptLanguageID>enu</RptLanguageID>
        <AccountDesc>WIP - Materials--GEN</AccountDesc>
        <AccountNum>00-0650-00</AccountNum>
        <BookID>DIVISIONS</BookID>
        <Company>STI</Company>
        <CRTranAmt>3.3</CRTranAmt>
        <DBTranAmt>0</DBTranAmt>
        <SegValue1>0650</SegValue1>
        <SegValue2>00</SegValue2>
        <SegValue3>00</SegValue3>
        <strSeqNumber>87</strSeqNumber>
        <strTrnDate>08/17/17</strTrnDate>
        <TmpJobNum>051096</TmpJobNum>
        <TmpPartNum>225980</TmpPartNum>
        <TmpReference>Supplier: SIL4 Inv: 0073262-IN</TmpReference>
        <TrnDate>2017-08-17</TrnDate>
        <TrnPosted>false</TrnPosted>
        <TrnType>ADJ-PUR</TrnType>
        <Calc_BookDesc>Divisional Book</Calc_BookDesc>
        <Calc_BookID>DIVISIONS</Calc_BookID>
        <Calc_CurrCode>BASE</Calc_CurrCode>
        <Calc_CurrDesc>GBP</Calc_CurrDesc>
    </Recon>
 

 

None of that is in the report that errors out

Reply