Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Visual Documents 2.0 categories in report crashs program
Message
From
29/12/2002 21:05:03
Michael Gass
Instructional Software, Inc.
Kirkland, Washington, United States
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
CodeMine
Title:
Visual Documents 2.0 categories in report crashs program
Miscellaneous
Thread ID:
00736473
Message ID:
00736473
Views:
69
I’m using Visual Documents 2.0, Codemine 7.0 and Visual Foxpro 7.0. I’m creating a report that loops through categories using DO WHILE NOT EOF() and a loop within that using SCAN WHILE that loops through items as long as the category has not changed. When the category changes the DO WHILE loop displays the next category and the SCAN WHILE loop then progresses through the view to display the set of data that relates to the currently selected category. Things work fine for a few categories. Problems occur when the categories are increased, which gradually slows the process until the program eventually crashes.

When looking at the temporary table created by VD I noticed that the paragraph field increases as it should in the SCAN loop but once the sequence hits the DO WHILE loop for a new category, the paragraph field jumps by the number of items in the SCAN loop, e.g. 4. The next time through it jumps by twice that number, e.g. 8. The next time through it’s twice that number, e.g. 16. It doesn’t take long and it has jumped to a point that it crashes the program.

I followed the code through the sequence and the error seems to occur in the VD COPYGROUP method at ‘IF THIS.FindTag(m.cTag2)’ and ‘m.nLast = paragraph’. This is where m.nLast and paragraph increase more than expected. I wasn’t able to track the problem beyond that point. My guess is that it has something to do with the way I set up the template in MS Word which was saved as an RTF file then called from a memo field.

All of my reports (50 or so) are doing the same thing. They work fine as long as there are relatively few categories in the report. Once the number of categories builds up, the program crashes.

Has anyone experienced this problem? Thanks!
Next
Reply
Map
View

Click here to load this message in the networking platform