Subcharts are group of statements that can be called in the main flowchart. Sub-charts help breaks a complex Raptor flowchart into logical sub pieces to simplify design and ensure that the main flowchart is manageable. Subcharts and Procedures solve complex problems by separating statements into groups of commands. We can invoke the subcharts and procedures using the Call symbol. Programmer-defined subcharts and procedures appear as tabs in the workspace next to the main tab.
Subchart vs Procedure
Subchart transfers control but we cannot pass parameters to a sub chart. Unlike, Subchart we can pass parameters to the procedure. Subchart can be added in both Novice and Intermediate modes. Procedure is available in Intermediate mode only.
When the main flowchart encounters the Call symbol, the control is transferred to the subchart. The subchart steps are executed. After the execution the control is transferred back to the main flowchart.
Creating a Subchart
By default when you start a Raptor flowchart, you will see the main tab with Start and End symbols. To create a sub chart, right-click the main tab and select Add sub chart from the menu as shown.
In the dialog box name the sub chart. Give a meaningful and crispy name to the sub chart based on the functionality of the sub chart.
Enter the name of your sub chart in the Name sub chart dialog box. A new tab would be created automatically with the name you give. Now you can begin to build your sub chart.
The Call symbol is used to call sub-charts from the main flowchart. Once you have created your sub chart, you can call the sub chart with the Call symbol. Insert the call symbol where you want it in your main flowchart, and enter the name of the sub chart that you want to be invoked.
When the flowchart runs, when the Call symbol is encountered the control will transfer to the sub chart. After all the steps in the sub chart are executed the control will be transferred to the next symbol after the Call symbol.
Demo Flowchart using Sub charts
RAPTOR Tutorial Page: https://www.testingdocs.com/raptor-a-flowchart-tool/
RAPTOR official website: https://raptor.martincarlisle.com/