d-verbuchen.w 8.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284
  1. &ANALYZE-SUSPEND _VERSION-NUMBER UIB_v8r12 GUI ADM1
  2. &ANALYZE-RESUME
  3. &Scoped-define WINDOW-NAME CURRENT-WINDOW
  4. &Scoped-define FRAME-NAME D-Dialog
  5. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _CUSTOM _DEFINITIONS D-Dialog
  6. /*------------------------------------------------------------------------
  7. File:
  8. Description: from cntnrdlg.w - ADM SmartDialog Template
  9. Input Parameters:
  10. <none>
  11. Output Parameters:
  12. <none>
  13. Author:
  14. Created:
  15. ------------------------------------------------------------------------*/
  16. /* This .W file was created with the Progress UIB. */
  17. /*----------------------------------------------------------------------*/
  18. /* Create an unnamed pool to store all the widgets created
  19. by this procedure. This is a good default which assures
  20. that this procedure's triggers and internal procedures
  21. will execute in this procedure's storage, and that proper
  22. cleanup will occur on deletion of the procedure. */
  23. CREATE WIDGET-POOL.
  24. /* *************************** Definitions ************************** */
  25. /* Parameters Definitions --- */
  26. /* Local Variable Definitions --- */
  27. /* ---------- Globale Variablen ---------------------------------- */
  28. { v8/globvar.i" " " " "SHARED" }
  29. { v8/debivar.i " " " " "SHARED" }
  30. { v8/artivar.i " " " " "SHARED" }
  31. { v8/contvar.i " " " " "SHARED" }
  32. /* _UIB-CODE-BLOCK-END */
  33. &ANALYZE-RESUME
  34. &ANALYZE-SUSPEND _UIB-PREPROCESSOR-BLOCK
  35. /* ******************** Preprocessor Definitions ******************** */
  36. &Scoped-define PROCEDURE-TYPE SmartDialog
  37. &Scoped-define DB-AWARE no
  38. &Scoped-define ADM-CONTAINER DIALOG-BOX
  39. /* Name of designated FRAME-NAME and/or first browse and/or first query */
  40. &Scoped-define FRAME-NAME D-Dialog
  41. /* Custom List Definitions */
  42. /* List-1,List-2,List-3,List-4,List-5,List-6 */
  43. /* _UIB-PREPROCESSOR-BLOCK-END */
  44. &ANALYZE-RESUME
  45. /* *********************** Control Definitions ********************** */
  46. /* Define a dialog box */
  47. /* Definitions of handles for SmartObjects */
  48. DEFINE VARIABLE h_v-verbuchen AS HANDLE NO-UNDO.
  49. /* ************************ Frame Definitions *********************** */
  50. DEFINE FRAME D-Dialog
  51. SPACE(108.47) SKIP(15.35)
  52. WITH VIEW-AS DIALOG-BOX KEEP-TAB-ORDER
  53. SIDE-LABELS NO-UNDERLINE THREE-D SCROLLABLE
  54. BGCOLOR 8
  55. TITLE "Verbuchen einer Rechnung".
  56. /* *********************** Procedure Settings ************************ */
  57. &ANALYZE-SUSPEND _PROCEDURE-SETTINGS
  58. /* Settings for THIS-PROCEDURE
  59. Type: SmartDialog
  60. Allow: Basic,Browse,DB-Fields,Query,Smart
  61. Other Settings: COMPILE
  62. */
  63. &ANALYZE-RESUME _END-PROCEDURE-SETTINGS
  64. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _CUSTOM _INCLUDED-LIB D-Dialog
  65. /* ************************* Included-Libraries *********************** */
  66. {src/adm/method/containr.i}
  67. /* _UIB-CODE-BLOCK-END */
  68. &ANALYZE-RESUME
  69. /* *********** Runtime Attributes and AppBuilder Settings *********** */
  70. &ANALYZE-SUSPEND _RUN-TIME-ATTRIBUTES
  71. /* SETTINGS FOR DIALOG-BOX D-Dialog
  72. FRAME-NAME */
  73. ASSIGN
  74. FRAME D-Dialog:SCROLLABLE = FALSE
  75. FRAME D-Dialog:HIDDEN = TRUE.
  76. /* _RUN-TIME-ATTRIBUTES-END */
  77. &ANALYZE-RESUME
  78. /* Setting information for Queries and Browse Widgets fields */
  79. &ANALYZE-SUSPEND _QUERY-BLOCK DIALOG-BOX D-Dialog
  80. /* Query rebuild information for DIALOG-BOX D-Dialog
  81. _Options = "SHARE-LOCK"
  82. _Query is NOT OPENED
  83. */ /* DIALOG-BOX D-Dialog */
  84. &ANALYZE-RESUME
  85. /* ************************ Control Triggers ************************ */
  86. &Scoped-define SELF-NAME D-Dialog
  87. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _CONTROL D-Dialog D-Dialog
  88. ON WINDOW-CLOSE OF FRAME D-Dialog /* Verbuchen einer Rechnung */
  89. DO:
  90. /* Add Trigger to equate WINDOW-CLOSE to END-ERROR. */
  91. APPLY "END-ERROR":U TO SELF.
  92. END.
  93. /* _UIB-CODE-BLOCK-END */
  94. &ANALYZE-RESUME
  95. &UNDEFINE SELF-NAME
  96. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _CUSTOM _MAIN-BLOCK D-Dialog
  97. /* *************************** Main Block *************************** */
  98. {src/adm/template/dialogmn.i}
  99. /* _UIB-CODE-BLOCK-END */
  100. &ANALYZE-RESUME
  101. /* ********************** Internal Procedures *********************** */
  102. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE adm-create-objects D-Dialog _ADM-CREATE-OBJECTS
  103. PROCEDURE adm-create-objects :
  104. /*------------------------------------------------------------------------------
  105. Purpose: Create handles for all SmartObjects used in this procedure.
  106. After SmartObjects are initialized, then SmartLinks are added.
  107. Parameters: <none>
  108. ------------------------------------------------------------------------------*/
  109. DEFINE VARIABLE adm-current-page AS INTEGER NO-UNDO.
  110. RUN get-attribute IN THIS-PROCEDURE ('Current-Page':U).
  111. ASSIGN adm-current-page = INTEGER(RETURN-VALUE).
  112. CASE adm-current-page:
  113. WHEN 0 THEN DO:
  114. RUN init-object IN THIS-PROCEDURE (
  115. INPUT 'v8/v-verbuchen.w':U ,
  116. INPUT FRAME D-Dialog:HANDLE ,
  117. INPUT 'Layout = ':U ,
  118. OUTPUT h_v-verbuchen ).
  119. RUN set-position IN h_v-verbuchen ( 2.14 , 10.20 ) NO-ERROR.
  120. /* Size in UIB: ( 13.00 , 90.80 ) */
  121. /* Adjust the tab order of the smart objects. */
  122. END. /* Page 0 */
  123. END CASE.
  124. END PROCEDURE.
  125. /* _UIB-CODE-BLOCK-END */
  126. &ANALYZE-RESUME
  127. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE adm-row-available D-Dialog _ADM-ROW-AVAILABLE
  128. PROCEDURE adm-row-available :
  129. /*------------------------------------------------------------------------------
  130. Purpose: Dispatched to this procedure when the Record-
  131. Source has a new row available. This procedure
  132. tries to get the new row (or foriegn keys) from
  133. the Record-Source and process it.
  134. Parameters: <none>
  135. ------------------------------------------------------------------------------*/
  136. /* Define variables needed by this internal procedure. */
  137. {src/adm/template/row-head.i}
  138. /* Process the newly available records (i.e. display fields,
  139. open queries, and/or pass records on to any RECORD-TARGETS). */
  140. {src/adm/template/row-end.i}
  141. END PROCEDURE.
  142. /* _UIB-CODE-BLOCK-END */
  143. &ANALYZE-RESUME
  144. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE disable_UI D-Dialog _DEFAULT-DISABLE
  145. PROCEDURE disable_UI :
  146. /*------------------------------------------------------------------------------
  147. Purpose: DISABLE the User Interface
  148. Parameters: <none>
  149. Notes: Here we clean-up the user-interface by deleting
  150. dynamic widgets we have created and/or hide
  151. frames. This procedure is usually called when
  152. we are ready to "clean-up" after running.
  153. ------------------------------------------------------------------------------*/
  154. /* Hide all frames. */
  155. HIDE FRAME D-Dialog.
  156. END PROCEDURE.
  157. /* _UIB-CODE-BLOCK-END */
  158. &ANALYZE-RESUME
  159. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE enable_UI D-Dialog _DEFAULT-ENABLE
  160. PROCEDURE enable_UI :
  161. /*------------------------------------------------------------------------------
  162. Purpose: ENABLE the User Interface
  163. Parameters: <none>
  164. Notes: Here we display/view/enable the widgets in the
  165. user-interface. In addition, OPEN all queries
  166. associated with each FRAME and BROWSE.
  167. These statements here are based on the "Other
  168. Settings" section of the widget Property Sheets.
  169. ------------------------------------------------------------------------------*/
  170. VIEW FRAME D-Dialog.
  171. {&OPEN-BROWSERS-IN-QUERY-D-Dialog}
  172. END PROCEDURE.
  173. /* _UIB-CODE-BLOCK-END */
  174. &ANALYZE-RESUME
  175. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE send-records D-Dialog _ADM-SEND-RECORDS
  176. PROCEDURE send-records :
  177. /*------------------------------------------------------------------------------
  178. Purpose: Send record ROWID's for all tables used by
  179. this file.
  180. Parameters: see template/snd-head.i
  181. ------------------------------------------------------------------------------*/
  182. /* SEND-RECORDS does nothing because there are no External
  183. Tables specified for this SmartDialog, and there are no
  184. tables specified in any contained Browse, Query, or Frame. */
  185. END PROCEDURE.
  186. /* _UIB-CODE-BLOCK-END */
  187. &ANALYZE-RESUME
  188. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE state-changed D-Dialog
  189. PROCEDURE state-changed :
  190. /* -----------------------------------------------------------
  191. Purpose:
  192. Parameters: <none>
  193. Notes:
  194. -------------------------------------------------------------*/
  195. DEFINE INPUT PARAMETER p-issuer-hdl AS HANDLE NO-UNDO.
  196. DEFINE INPUT PARAMETER p-state AS CHARACTER NO-UNDO.
  197. END PROCEDURE.
  198. /* _UIB-CODE-BLOCK-END */
  199. &ANALYZE-RESUME