An old friend of mine was having some trouble with Visual Basic 6 and Crystal reports. Here is what he told me his problem was and the solution he found.
A ticket was assigned to me to look at a report that was not displaying all the data. The report displayed just 19 pages. The user said he/she was expecting around 40 pages…. After hours of trying different things I found the problem….
·The Report had a sub-report
·The 19 pages represented the main report
·The sub-report was not showing because the VB6 code is dynamically creating SQL that is passed to the report. It just happened that when one of the parameters (user entered thru the UI) was 0 (zero)
·The VB6 code was doing Format$(USER_PARAMETER, "######") this caused the value to be empty