Crystal Report Does not display properly - Invalid Index

0

I have a crystal report in my project. Whenever I am trying to open that page, This exception appear.

Crystal Report: Invalid index. (Exception from HRESULT: 0x8002000B (DISP_E_BADINDEX))

In my Crystal Report, I have a Parameter Fields named isEffective (Boolean type). When I run the program and the debug point hit report1.SetParameterVlaue, this exception appear. However, when I comment this line, there is no exception.

Report report1 = Report();
report1.SetParameterValue("isEffective", true);
c#
crystal-reports
asked on Stack Overflow Sep 6, 2016 by RedRocket • edited Sep 6, 2016 by RedRocket

1 Answer

0

try this

report1.SetParameterValue("@isEffective", true);

Some time this error occurs when your parameters not matched in both reports & coding. May be your parameter name is wrong. So verify the parameters & parameter names are same in report & your coding.

answered on Stack Overflow Sep 6, 2016 by Shakir Ahamed

User contributions licensed under CC BY-SA 3.0