PWCT 1.9 Art Documentation ( http://doublesvsoop.sourceforge.net ) 2006-2019, Mahmoud Fayed ( msfclipper@users.sourceforge.net ) _____________________________________________________________________________________ Table of contents 1 - Introduction 2 - Implementation steps 3 - Final Steps Tree 1 - Introduction In this lesson we are going to create the (Access Report - Child Class) template. 2 - Implementation Steps Fig. (1) Goal Desginer - Steps Tree Select the step (Set Class Name & Window Name) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (PWCT - Code Generator) 3 - Select the component (CG Replace String) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (CG Replace String) Note : Stop typing when you see the required component is selected Fig. (2) Component Browser – Select the component (CG Replace String) After selecting the component click Ok or press ENTER Fig. (3) Interaction page - Set the properties and enter the required data as in the image above Fig. (4) Goal Desginer - Steps Tree Select the step (Set Class Name & Window Name) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (PWCT - Code Generator) 3 - Select the component (CG Replace String) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (CG Replace String) Note : Stop typing when you see the required component is selected Fig. (5) Component Browser – Select the component (CG Replace String) After selecting the component click Ok or press ENTER Fig. (6) Interaction page - Set the properties and enter the required data as in the image above Fig. (7) Goal Desginer - Steps Tree Select the step (Class) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Define Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define Class) Note : Stop typing when you see the required component is selected Fig. (8) Component Browser – Select the component (Define Class) After selecting the component click Ok or press ENTER Fig. (9) Interaction page - Set the properties and enter the required data as in the image above Fig. (10) Goal Desginer - Steps Tree Select the step (Declare Class Data) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Declare Class Data) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Declare Class Data) Note : Stop typing when you see the required component is selected Fig. (11) Component Browser – Select the component (Declare Class Data) After selecting the component click Ok or press ENTER Fig. (12) Interaction page - Set the properties and enter the required data as in the image above Fig. (13) Goal Desginer - Steps Tree Select the step (Declare Class Data) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Declare Class Data) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Declare Class Data) Note : Stop typing when you see the required component is selected Fig. (14) Component Browser – Select the component (Declare Class Data) After selecting the component click Ok or press ENTER Fig. (15) Interaction page - Set the properties and enter the required data as in the image above Fig. (16) Goal Desginer - Steps Tree Select the step (Declare Class Methods) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Declare Class Method) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Declare Class Method) Note : Stop typing when you see the required component is selected Fig. (17) Component Browser – Select the component (Declare Class Method) After selecting the component click Ok or press ENTER Fig. (18) Interaction page - Set the properties and enter the required data as in the image above Fig. (19) Goal Desginer - Steps Tree Select the step (Declare Class Methods) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Declare Class Method) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Declare Class Method) Note : Stop typing when you see the required component is selected Fig. (20) Component Browser – Select the component (Declare Class Method) After selecting the component click Ok or press ENTER Fig. (21) Interaction page - Set the properties and enter the required data as in the image above Fig. (22) Goal Desginer - Steps Tree Select the step (Declare Class Methods) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Declare Class Method) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Declare Class Method) Note : Stop typing when you see the required component is selected Fig. (23) Component Browser – Select the component (Declare Class Method) After selecting the component click Ok or press ENTER Fig. (24) Interaction page - Set the properties and enter the required data as in the image above Fig. (25) Goal Desginer - Steps Tree Select the step (Class Methods) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Define Class Method) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define Class Method) Note : Stop typing when you see the required component is selected Fig. (26) Component Browser – Select the component (Define Class Method) After selecting the component click Ok or press ENTER Fig. (27) Interaction page - Set the properties and enter the required data as in the image above Fig. (28) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Define New Window) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define New Window) Note : Stop typing when you see the required component is selected Fig. (29) Component Browser – Select the component (Define New Window) After selecting the component click Ok or press ENTER Fig. (30) Interaction page - Set the properties and enter the required data as in the image above Fig. (31) Form Designer Fig. (32) Goal Desginer - Steps Tree Select the step (Window Events) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Window Events) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Window Events) Note : Stop typing when you see the required component is selected Fig. (33) Component Browser – Select the component (Window Events) After selecting the component click Ok or press ENTER Fig. (34) Interaction page - Set the properties and enter the required data as in the image above Fig. (35) Form Designer Fig. (36) Goal Desginer - Steps Tree Select the step (Window Events) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Window Events) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Window Events) Note : Stop typing when you see the required component is selected Fig. (37) Component Browser – Select the component (Window Events) After selecting the component click Ok or press ENTER Fig. (38) Interaction page - Set the properties and enter the required data as in the image above Fig. (39) Form Designer Fig. (40) Goal Desginer - Steps Tree Select the step (Window Events) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Window Events) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Window Events) Note : Stop typing when you see the required component is selected Fig. (41) Component Browser – Select the component (Window Events) After selecting the component click Ok or press ENTER Fig. (42) Interaction page - Set the properties and enter the required data as in the image above Fig. (43) Form Designer Fig. (44) Goal Desginer - Steps Tree Select the step (Window Controls) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Controls) 3 - Select the component (Button) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button) Note : Stop typing when you see the required component is selected Fig. (45) Component Browser – Select the component (Button) After selecting the component click Ok or press ENTER Fig. (46) Interaction page - Set the properties and enter the required data as in the image above Fig. (47) Form Designer Fig. (48) Goal Desginer - Steps Tree Select the step (Button Events) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Events) 3 - Select the component (Button Events) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button Events) Note : Stop typing when you see the required component is selected Fig. (49) Component Browser – Select the component (Button Events) After selecting the component click Ok or press ENTER Fig. (50) Interaction page - Set the properties and enter the required data as in the image above Fig. (51) Goal Desginer - Steps Tree Select the step (Window Controls) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Controls) 3 - Select the component (Button) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button) Note : Stop typing when you see the required component is selected Fig. (52) Component Browser – Select the component (Button) After selecting the component click Ok or press ENTER Fig. (53) Interaction page - Set the properties and enter the required data as in the image above Fig. (54) Form Designer Fig. (55) Goal Desginer - Steps Tree Select the step (Button Events) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Events) 3 - Select the component (Button Events) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button Events) Note : Stop typing when you see the required component is selected Fig. (56) Component Browser – Select the component (Button Events) After selecting the component click Ok or press ENTER Fig. (57) Interaction page - Set the properties and enter the required data as in the image above Fig. (58) Goal Desginer - Steps Tree Select the step (Window Controls) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Controls) 3 - Select the component (Button) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button) Note : Stop typing when you see the required component is selected Fig. (59) Component Browser – Select the component (Button) After selecting the component click Ok or press ENTER Fig. (60) Interaction page - Set the properties and enter the required data as in the image above Fig. (61) Form Designer Fig. (62) Goal Desginer - Steps Tree Select the step (Button Events) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Events) 3 - Select the component (Button Events) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button Events) Note : Stop typing when you see the required component is selected Fig. (63) Component Browser – Select the component (Button Events) After selecting the component click Ok or press ENTER Fig. (64) Interaction page - Set the properties and enter the required data as in the image above Fig. (65) Goal Desginer - Steps Tree Select the step (Window Controls) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (ActiveX) 3 - Select the component (Define ActiveX control) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define ActiveX control) Note : Stop typing when you see the required component is selected Fig. (66) Component Browser – Select the component (Define ActiveX control) After selecting the component click Ok or press ENTER Fig. (67) Interaction page - Set the properties and enter the required data as in the image above Fig. (68) Form Designer Fig. (69) Goal Desginer - Steps Tree Select the step (Define New Window ( MyWindowName ) , Title : "Report") We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Window Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Window Class) Note : Stop typing when you see the required component is selected Fig. (70) Component Browser – Select the component (Window Class) After selecting the component click Ok or press ENTER Fig. (71) Interaction page - Set the properties and enter the required data as in the image above Fig. (72) Interaction page - Set the properties and enter the required data as in the image above Fig. (73) Interaction page - Set the properties and enter the required data as in the image above Fig. (74) Form Designer Fig. (75) Goal Desginer - Steps Tree Select the step (Class Methods) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Define Class Method) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define Class Method) Note : Stop typing when you see the required component is selected Fig. (76) Component Browser – Select the component (Define Class Method) After selecting the component click Ok or press ENTER Fig. (77) Interaction page - Set the properties and enter the required data as in the image above Fig. (78) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Window Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Window Class) Note : Stop typing when you see the required component is selected Fig. (79) Component Browser – Select the component (Window Class) After selecting the component click Ok or press ENTER Fig. (80) Interaction page - Set the properties and enter the required data as in the image above Fig. (81) Interaction page - Set the properties and enter the required data as in the image above Fig. (82) Interaction page - Set the properties and enter the required data as in the image above Fig. (83) Goal Desginer - Steps Tree Select the step (Class Methods) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Object Oriented Programming (OOP)) 3 - Select the component (Define Class Method) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define Class Method) Note : Stop typing when you see the required component is selected Fig. (84) Component Browser – Select the component (Define Class Method) After selecting the component click Ok or press ENTER Fig. (85) Interaction page - Set the properties and enter the required data as in the image above Fig. (86) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Structure Programming) 3 - Select the component (Scope of Variable) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Scope of Variable) Note : Stop typing when you see the required component is selected Fig. (87) Component Browser – Select the component (Scope of Variable) After selecting the component click Ok or press ENTER Fig. (88) Interaction page - Set the properties and enter the required data as in the image above Fig. (89) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Window Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Window Class) Note : Stop typing when you see the required component is selected Fig. (90) Component Browser – Select the component (Window Class) After selecting the component click Ok or press ENTER Fig. (91) Interaction page - Set the properties and enter the required data as in the image above Fig. (92) Interaction page - Set the properties and enter the required data as in the image above Fig. (93) Interaction page - Set the properties and enter the required data as in the image above Fig. (94) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Windows) 3 - Select the component (Window Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Window Class) Note : Stop typing when you see the required component is selected Fig. (95) Component Browser – Select the component (Window Class) After selecting the component click Ok or press ENTER Fig. (96) Interaction page - Set the properties and enter the required data as in the image above Fig. (97) Interaction page - Set the properties and enter the required data as in the image above Fig. (98) Interaction page - Set the properties and enter the required data as in the image above Fig. (99) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (ActiveX) 3 - Select the component (ActiveX Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ActiveX Class) Note : Stop typing when you see the required component is selected Fig. (100) Component Browser – Select the component (ActiveX Class) After selecting the component click Ok or press ENTER Fig. (101) Interaction page - Set the properties and enter the required data as in the image above Fig. (102) Interaction page - Set the properties and enter the required data as in the image above Fig. (103) Interaction page - Set the properties and enter the required data as in the image above Fig. (104) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (ActiveX) 3 - Select the component (ActiveX Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ActiveX Class) Note : Stop typing when you see the required component is selected Fig. (105) Component Browser – Select the component (ActiveX Class) After selecting the component click Ok or press ENTER Fig. (106) Interaction page - Set the properties and enter the required data as in the image above Fig. (107) Interaction page - Set the properties and enter the required data as in the image above Fig. (108) Interaction page - Set the properties and enter the required data as in the image above Fig. (109) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Classes) 3 - Select the component (Button Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button Class) Note : Stop typing when you see the required component is selected Fig. (110) Component Browser – Select the component (Button Class) After selecting the component click Ok or press ENTER Fig. (111) Interaction page - Set the properties and enter the required data as in the image above Fig. (112) Interaction page - Set the properties and enter the required data as in the image above Fig. (113) Interaction page - Set the properties and enter the required data as in the image above Fig. (114) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Classes) 3 - Select the component (Button Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button Class) Note : Stop typing when you see the required component is selected Fig. (115) Component Browser – Select the component (Button Class) After selecting the component click Ok or press ENTER Fig. (116) Interaction page - Set the properties and enter the required data as in the image above Fig. (117) Interaction page - Set the properties and enter the required data as in the image above Fig. (118) Interaction page - Set the properties and enter the required data as in the image above Fig. (119) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (Classes) 3 - Select the component (Button Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Button Class) Note : Stop typing when you see the required component is selected Fig. (120) Component Browser – Select the component (Button Class) After selecting the component click Ok or press ENTER Fig. (121) Interaction page - Set the properties and enter the required data as in the image above Fig. (122) Interaction page - Set the properties and enter the required data as in the image above Fig. (123) Interaction page - Set the properties and enter the required data as in the image above Fig. (124) Goal Desginer - Steps Tree Select the step (Start Here) We will start now new interaction process to generate new steps to our steps tree. The slow way (Using Mouse): 1 - Click Interact to open the components browser 2 - Select the domain (ActiveX) 3 - Select the component (ActiveX Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ActiveX Class) Note : Stop typing when you see the required component is selected Fig. (125) Component Browser – Select the component (ActiveX Class) After selecting the component click Ok or press ENTER Fig. (126) Interaction page - Set the properties and enter the required data as in the image above Fig. (127) Interaction page - Set the properties and enter the required data as in the image above Fig. (128) Interaction page - Set the properties and enter the required data as in the image above Fig. (129) Goal Desginer - Final Steps Tree 3 - Final Steps Tree Set Class Name & Window Name PWCT-Code Generator: Replace String (MyClassName) with (ReportClass) PWCT-Code Generator: Replace String (MyWindowName) with (&(self:cWindowName)) Class Define Class MyClassName From Report_Base Declare Class Data Data ReportName Init Value "ReportName" Data cWindowName Init Value "ReportWindow" Declare Class Methods Method showwindow Method closewindow Method SizeReport End of Class Class Methods Define Method ShowWindow Class MyClassName Start Here Define New Window ( MyWindowName ) , Title : "Report" Window Events Event: ON INIT : Action self:ShowReport() Event: ON SIZE : Action self:SizeReport() Event: ON MAXIMIZE : Action self:SizeReport() Window Properties Window Controls Define New Button ( btn1 ) , Caption : "Close" Button Events Event: ON CLICK : Action self:CloseWindow() Button Properties Define New Button ( btn2 ) , Caption : "Print" Button Events Event: ON CLICK : Action self:PrintReport() Button Properties Define New Button ( btn3 ) , Caption : "Refresh" Button Events Event: ON CLICK : Action self:ShowReport() Button Properties Active Control ( self:oActiveX ) End Of Window MyWindowName.Maximize ( ) Activate window End of Method (Return 0) Define Method CloseWindow Class MyClassName Start Here MyWindowName.Release ( ) End of Method (Return 0) Define Method SizeReport Class MyClassName Start Here Local tempvar1,tempvar2 tempvar1 = MyWindowName.Width tempvar2 = MyWindowName.Height self:oactivex.nWidth := tempvar1 - 84 self:oactivex.nHeight := tempvar2 - 125 MyWindowName.btn1.Row := tempvar2-88 MyWindowName.btn2.Row := tempvar2-88 MyWindowName.btn3.Row := tempvar2-88 self:oactivex.Show ( ) End of Method (Return 0)
|