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 4 - Application during the runtime 1 - Introduction In this lesson we are going to learn how to 1 - connect to access database using Microsoft ADO (ActiveX Data Object). 2 - Add new record to a table in our database. 3 - Show table records using a Grid control. 2 - Implementation Steps Fig. (1) Goal Desginer - Steps Tree Select the step (The First Step) 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. (2) Component Browser – Select the component (Define New Window) 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 Afer entering data , Click OK or press CTRL+W Fig. (4) Form Designer Fig. (5) 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 (Image) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Image) Note : Stop typing when you see the required component is selected Fig. (6) Component Browser – Select the component (Image) After selecting the component click Ok or press ENTER Fig. (7) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (8) Form Designer Fig. (9) 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 (Label) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Label) Note : Stop typing when you see the required component is selected Fig. (10) Component Browser – Select the component (Label) After selecting the component click Ok or press ENTER Fig. (11) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (12) Form Designer Fig. (13) 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 (Label) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Label) Note : Stop typing when you see the required component is selected Fig. (14) Component Browser – Select the component (Label) 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 Afer entering data , Click OK or press CTRL+W Fig. (16) Form Designer Fig. (17) 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 (Label) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Label) Note : Stop typing when you see the required component is selected Fig. (18) Component Browser – Select the component (Label) After selecting the component click Ok or press ENTER Fig. (19) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (20) Form Designer Fig. (21) 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 (TextBox) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (TextBox) Note : Stop typing when you see the required component is selected Fig. (22) Component Browser – Select the component (TextBox) After selecting the component click Ok or press ENTER Fig. (23) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (24) Form Designer Fig. (25) 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 (TextBox) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (TextBox) Note : Stop typing when you see the required component is selected Fig. (26) Component Browser – Select the component (TextBox) 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 Afer entering data , Click OK or press CTRL+W Fig. (28) Form Designer Fig. (29) 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 (TextBox) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (TextBox) Note : Stop typing when you see the required component is selected Fig. (30) Component Browser – Select the component (TextBox) After selecting the component click Ok or press ENTER Fig. (31) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (32) Form Designer Fig. (33) 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. (34) Component Browser – Select the component (Button) After selecting the component click Ok or press ENTER Fig. (35) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (36) Form Designer Fig. (37) 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. (38) Component Browser – Select the component (Button Events) After selecting the component click Ok or press ENTER Fig. (39) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (40) 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. (41) Component Browser – Select the component (Button) 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 Afer entering data , Click OK or press CTRL+W Fig. (43) Form Designer Fig. (44) 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. (45) Component Browser – Select the component (Button Events) 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 Afer entering data , Click OK or press CTRL+W Fig. (47) 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 (Grid Control) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Grid Control) Note : Stop typing when you see the required component is selected Fig. (48) Component Browser – Select the component (Grid Control) After selecting the component click Ok or press ENTER Fig. (49) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (50) Form Designer 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 Afer entering data , Click OK or press CTRL+W 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 Afer entering data , Click OK or press CTRL+W 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 (Label) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Label) Note : Stop typing when you see the required component is selected Fig. (59) Component Browser – Select the component (Label) 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 Afer entering data , Click OK or press CTRL+W Fig. (61) Form Designer Fig. (62) 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 (TextBox) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (TextBox) Note : Stop typing when you see the required component is selected Fig. (63) Component Browser – Select the component (TextBox) 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 Afer entering data , Click OK or press CTRL+W Fig. (65) Form Designer Fig. (66) Goal Desginer - Steps Tree Select the step (The First Step) 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 (Define Procedure) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define Procedure) Note : Stop typing when you see the required component is selected Fig. (67) Component Browser – Select the component (Define Procedure) After selecting the component click Ok or press ENTER Fig. (68) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (69) 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. (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 Afer entering data , Click OK or press CTRL+W Fig. (72) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (73) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (74) Goal Desginer - Steps Tree Select the step (The First Step) 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 (Define Procedure) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define Procedure) Note : Stop typing when you see the required component is selected Fig. (75) Component Browser – Select the component (Define Procedure) After selecting the component click Ok or press ENTER Fig. (76) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (77) 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 (Connection) 3 - Select the component (ADO New Connection) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO New Connection) Note : Stop typing when you see the required component is selected Fig. (78) Component Browser – Select the component (ADO New Connection) After selecting the component click Ok or press ENTER Fig. (79) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (80) 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 (Connection) 3 - Select the component (ADO Open Connection) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Open Connection) Note : Stop typing when you see the required component is selected Fig. (81) Component Browser – Select the component (ADO Open Connection) After selecting the component click Ok or press ENTER Fig. (82) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (83) 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 (RecordSet) 3 - Select the component (ADO New RecordSet) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO New RecordSet) Note : Stop typing when you see the required component is selected Fig. (84) Component Browser – Select the component (ADO New RecordSet) 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 Afer entering data , Click OK or press CTRL+W 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 (RecordSet) 3 - Select the component (ADO Open RecordSet) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Open RecordSet) Note : Stop typing when you see the required component is selected Fig. (87) Component Browser – Select the component (ADO Open RecordSet) 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 Afer entering data , Click OK or press CTRL+W 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 (RecordSet) 3 - Select the component (ADO Add New Record) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Add New Record) Note : Stop typing when you see the required component is selected Fig. (90) Component Browser – Select the component (ADO Add New Record) 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 Afer entering data , Click OK or press CTRL+W Fig. (92) 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 (Textbox Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Textbox Class) Note : Stop typing when you see the required component is selected Fig. (93) Component Browser – Select the component (Textbox Class) After selecting the component click Ok or press ENTER Fig. (94) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (95) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (96) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (97) 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 (Textbox Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Textbox Class) Note : Stop typing when you see the required component is selected Fig. (98) Component Browser – Select the component (Textbox Class) After selecting the component click Ok or press ENTER Fig. (99) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (100) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (101) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (102) 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 (Textbox Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Textbox Class) Note : Stop typing when you see the required component is selected Fig. (103) Component Browser – Select the component (Textbox Class) After selecting the component click Ok or press ENTER Fig. (104) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (105) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (106) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (107) 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 (Textbox Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Textbox Class) Note : Stop typing when you see the required component is selected Fig. (108) Component Browser – Select the component (Textbox Class) After selecting the component click Ok or press ENTER Fig. (109) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (110) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (111) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (112) 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 (RecordSet) 3 - Select the component (ADO Set Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Set Field Value) Note : Stop typing when you see the required component is selected Fig. (113) Component Browser – Select the component (ADO Set Field Value) After selecting the component click Ok or press ENTER Fig. (114) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (115) 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 (RecordSet) 3 - Select the component (ADO Set Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Set Field Value) Note : Stop typing when you see the required component is selected Fig. (116) Component Browser – Select the component (ADO Set Field Value) After selecting the component click Ok or press ENTER Fig. (117) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (118) 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 (RecordSet) 3 - Select the component (ADO Set Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Set Field Value) Note : Stop typing when you see the required component is selected Fig. (119) Component Browser – Select the component (ADO Set Field Value) After selecting the component click Ok or press ENTER Fig. (120) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (121) 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 (RecordSet) 3 - Select the component (ADO Set Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Set Field Value) Note : Stop typing when you see the required component is selected Fig. (122) Component Browser – Select the component (ADO Set Field Value) After selecting the component click Ok or press ENTER Fig. (123) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W 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 (RecordSet) 3 - Select the component (ADO Update Record) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Update Record) Note : Stop typing when you see the required component is selected Fig. (125) Component Browser – Select the component (ADO Update Record) 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 Afer entering data , Click OK or press CTRL+W Fig. (127) 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 (RecordSet) 3 - Select the component (ADO Close RecordSet) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Close RecordSet) Note : Stop typing when you see the required component is selected Fig. (128) Component Browser – Select the component (ADO Close RecordSet) After selecting the component click Ok or press ENTER Fig. (129) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (130) 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 (Connection) 3 - Select the component (ADO Close Connection) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Close Connection) Note : Stop typing when you see the required component is selected Fig. (131) Component Browser – Select the component (ADO Close Connection) After selecting the component click Ok or press ENTER Fig. (132) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (133) 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 (GUI Application) 3 - Select the component (Show Message) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Show Message) Note : Stop typing when you see the required component is selected Fig. (134) Component Browser – Select the component (Show Message) After selecting the component click Ok or press ENTER Fig. (135) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (136) Goal Desginer - Steps Tree Select the step (The First Step) 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 (Define Procedure) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Define Procedure) Note : Stop typing when you see the required component is selected Fig. (137) Component Browser – Select the component (Define Procedure) After selecting the component click Ok or press ENTER Fig. (138) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (139) 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 (Connection) 3 - Select the component (ADO New Connection) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO New Connection) Note : Stop typing when you see the required component is selected Fig. (140) Component Browser – Select the component (ADO New Connection) After selecting the component click Ok or press ENTER Fig. (141) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (142) 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 (Connection) 3 - Select the component (ADO Open Connection) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Open Connection) Note : Stop typing when you see the required component is selected Fig. (143) Component Browser – Select the component (ADO Open Connection) After selecting the component click Ok or press ENTER Fig. (144) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (145) 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 (RecordSet) 3 - Select the component (ADO New RecordSet) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO New RecordSet) Note : Stop typing when you see the required component is selected Fig. (146) Component Browser – Select the component (ADO New RecordSet) After selecting the component click Ok or press ENTER Fig. (147) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (148) 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 (RecordSet) 3 - Select the component (ADO Open RecordSet) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Open RecordSet) Note : Stop typing when you see the required component is selected Fig. (149) Component Browser – Select the component (ADO Open RecordSet) After selecting the component click Ok or press ENTER Fig. (150) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (151) 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 (RecordSet) 3 - Select the component (ADO Get Records Count) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Get Records Count) Note : Stop typing when you see the required component is selected Fig. (152) Component Browser – Select the component (ADO Get Records Count) After selecting the component click Ok or press ENTER Fig. (153) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (154) 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 (Grid Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Grid Class) Note : Stop typing when you see the required component is selected Fig. (155) Component Browser – Select the component (Grid Class) After selecting the component click Ok or press ENTER Fig. (156) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (157) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (158) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (159) 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 (Control Structure) 3 - Select the component (For Loop) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (For Loop) Note : Stop typing when you see the required component is selected Fig. (160) Component Browser – Select the component (For Loop) After selecting the component click Ok or press ENTER Fig. (161) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (162) 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 (RecordSet) 3 - Select the component (ADO Get Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Get Field Value) Note : Stop typing when you see the required component is selected Fig. (163) Component Browser – Select the component (ADO Get Field Value) After selecting the component click Ok or press ENTER Fig. (164) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (165) 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 (RecordSet) 3 - Select the component (ADO Get Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Get Field Value) Note : Stop typing when you see the required component is selected Fig. (166) Component Browser – Select the component (ADO Get Field Value) After selecting the component click Ok or press ENTER Fig. (167) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (168) 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 (RecordSet) 3 - Select the component (ADO Get Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Get Field Value) Note : Stop typing when you see the required component is selected Fig. (169) Component Browser – Select the component (ADO Get Field Value) After selecting the component click Ok or press ENTER Fig. (170) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (171) 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 (RecordSet) 3 - Select the component (ADO Get Field Value) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Get Field Value) Note : Stop typing when you see the required component is selected Fig. (172) Component Browser – Select the component (ADO Get Field Value) After selecting the component click Ok or press ENTER Fig. (173) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (174) 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 (Grid Class) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (Grid Class) Note : Stop typing when you see the required component is selected Fig. (175) Component Browser – Select the component (Grid Class) After selecting the component click Ok or press ENTER Fig. (176) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (177) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (178) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (179) 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 (RecordSet) 3 - Select the component (ADO Goto Next Record) The fast way (Using Keyboard shortcuts): 1 - Get the component using its name by typing (ADO Goto Next Record) Note : Stop typing when you see the required component is selected Fig. (180) Component Browser – Select the component (ADO Goto Next Record) After selecting the component click Ok or press ENTER Fig. (181) Interaction page - Set the properties and enter the required data as in the image above Afer entering data , Click OK or press CTRL+W Fig. (182) Goal Desginer - Final Steps Tree 3 - Final Steps Tree The First Step Define New Window ( win1 ) , Title : "patient database" Window Events Window Properties Window Controls Define New Image ( image2 ) , Image : "HOSPITAL1.JPG" Events Properties Define Label ( lbl1 ) , Caption : "phone" Label Events Label Properties Define Label ( lbl2 ) , Caption : "patient name" Label Events Label Properties Define Label ( lbl3 ) , Caption : "address" Label Events Label Properties Define TextBox ( text1 ) TextBox EVENTS TextBox Properties Define TextBox ( text2 ) TextBox EVENTS TextBox Properties Define TextBox ( text3 ) TextBox EVENTS TextBox Properties Define New Button ( btn1 ) , Caption : "save record" Button Events Event: ON CLICK : Action saverec() Button Properties Define New Button ( btn2 ) , Caption : "Close" Button Events Event: ON CLICK : Action myClose() Button Properties Define New Grid ( Grid1 ) , HEADERS : {"Patient name","address","phone","Gender"} Events Properties Define New Button ( btn3 ) , Caption : "show Records" Button Events Event: ON CLICK : Action showrec() Button Properties Define Label ( lbl4 ) , Caption : "Gender" Label Events Label Properties Define TextBox ( text4 ) TextBox EVENTS TextBox Properties End Of Window Activate window Define Procedure myClose Start Here win1.Release ( ) End of Procedure Define Procedure saverec Start Here oCon = Create New ADODB Connection Open ADODB Connection oCon , Connection String : 'Provider=MSDASQL.1;Persist Security Info=False;Extended Properties="dsn=MS Access Database;uid=";Initial Catalog=data.mdb' oRS = Create New ADODB RecordSet Object Open Recordset oRS , Connection oCon , CursorType 1 , SQL Statement "Select * from patient" ADODB RecordSet oRS - Add New Record oname = win1.text1.Value oaddress = win1.text2.Value ophone = win1.text3.Value ogender = win1.text4.Value ADODB RecordSet (oRS) Set Field ("patient name") Value To (oname) ADODB RecordSet (oRS) Set Field ("address") Value To (oaddress) ADODB RecordSet (oRS) Set Field ("phone") Value To (ophone) ADODB RecordSet (oRS) Set Field ("Gender") Value To (ogender) ADODB RecordSet oRS - Update Record Close ADODB RecordSet oRS Close ADODB Connection oCon Show Message " Done " Title "ok" Type: Message Box End of Procedure Define Procedure showrec Start Here oCon = Create New ADODB Connection Open ADODB Connection oCon , Connection String : 'Provider=MSDASQL.1;Persist Security Info=False;Extended Properties="dsn=MS Access Database;uid=";Initial Catalog=data.mdb' oRS = Create New ADODB RecordSet Object Open Recordset oRS , Connection oCon , CursorType 1 , SQL Statement "Select * from patient" mymax := ADODB RecordSet (oRS) , Get Records Count win1.grid1.DeleteAllItems ( ) FOR LOOP ( From x = 1 To mymax Step 1) Start Here oname = ADODB RecordSet (oRS) Get Field ("patient name") Value oaddress = ADODB RecordSet (oRS) Get Field ("address") Value ophone = ADODB RecordSet (oRS) Get Field ("phone") Value ogender = ADODB RecordSet (oRS) Get Field ("gender") Value win1.grid1.AddItem ( {oname,oaddress,ophone,ogender} ) ADODB RecordSet oRS - Goto Next Record End of For Loop End of Procedure 4 - Application during the runtime Fig. (183) Application during the runtime
|