I’m building a customizable form in Perspective using a multilayered structure of views inside flex repeaters, which goes something like this (from top level to bottom level):
Main Page -> Section -> Question -> Answer
There are multiple sections with multiple questions per section and multiple answers (usually in the form of checkboxes) per question.
The instances property on each flex repeater is bound to a SQL query, with all of the information needed to generate the form stored in a database. The idea is that authorized users will be able to add, remove or edit parts of the form via a separate program.
The program worked well up until I added a “submit” button and started trying to dig down into the flex repeater instances to retrieve the responses to each question. When the button is pressed, I use several nested for loops to print out the information for each section, question and answer to the console. However, when the script gets to the first answer for Section 1, Question 1, it seems to get stuck without producing any errors.
In addition to this, I’ve started seeing extremely heavy memory usage when opening the project in the designer or browser. Opening the views one by one in the designer takes a while, with the screen showing “synchronizing” and the memory usage gradually increasing. Eventually the memory usage will max out at around 16 GB and things will start to lock up. Hitting the “submit” button in the browser results in similar behavior. I assume this has something to do with the way my views are passing parameters back and forth but I’m not sure how to pinpoint what exactly is causing the problem. This is the only project on the gateway and the logs don’t really tell me anything either.
Does anyone have any idea why this is happening or suggestions for how to troubleshoot it further?