Indexing out of range

nverma
Member Posts: 396
There is a report that is throwing this error message.
The indexing 0 in the array is outside of the permitted range. The name of the report is Reason for Termination. It just started happening recently. I tried debugging it and this is the line the system is throwing this error message on.
gdecPercentRate (Decimal Type) has dimension value set to 100000
gintCountRec (Integer Type) has dimension value set to 100000
I have tried to increase the size of the dimension value. But that didn't work. Its still throwing the same error message.
The indexing 0 in the array is outside of the permitted range. The name of the report is Reason for Termination. It just started happening recently. I tried debugging it and this is the line the system is throwing this error message on.
gdecPrecentRate[i] := (gintCountRec[i] / gintNumOfRecrods ) * 100;
gdecPercentRate (Decimal Type) has dimension value set to 100000
gintCountRec (Integer Type) has dimension value set to 100000
I have tried to increase the size of the dimension value. But that didn't work. Its still throwing the same error message.
0
Comments
-
-
You were right Den, while debugging I noticed that gdecPercentRate = 0 and the variable "i" = 0.
To try to fix it, I initialized i :=1;
IF gintNumOfRecords <> 0 THEN i := i + 1; gdecPrecentRate[i] := (gintCountRec[i] / gintNumOfRecrods ) * 100;
now the report is not displaying that error message. But the report is going haywire, its not displaying the output properly.
I am not sure if incrementing the i is the way to solve it... Why did this message start appearing now, the report was working fine previously.0 -
nverma wrote:Why did this message start appearing now, the report was working fine previously.0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions