Sage-ST ä

Dialog

Documentation

Close CreateCustomDialog CreateDialogHandle CreateModal
CreateModalExtra CreateModeless CreateModelessExtra CurrentDialogID
DestroyDialogHandle DialogCommand Disable Enable
Flush GetContextHelpControlID GetContextHelpID GetCustomDialogExtra
GetDialogPositionInfo GetExtra GetOriginalDialogID Hide
IsEnabled Redraw Reset STRSetContextHelpMsg
SetContextHelpMsg SetCustomDialogExtra SetCustomDialogPropSheetFlag SetCustomDialogUserProc
SetFocus SetParent Show




  function DialogCommand
             (const msgType : DWSpec.DisplayMessageType) : DialogMessage; stdcall;

  exports DialogCommand name 'Dialog_DialogCommand';

  //*
  //  DialogCommand - Retrieves a command which has been sent to a dialog.
  //
  //
  //  This routine will retrieve a command which has been sent to the
  //  dialog's ActionProc.
  //
  //  CALLING SEQUENCE -
  //
  //    command := DialogCommand (msgType)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    command : DialogMessage
  //      The command which has been sent.  Must be one of the Dialog
  //      Messages.  The command Unknown indicates an undefined command
  //      has been sent.
  //




  procedure Close
             (const dialogID : cardinal); stdcall;

  exports Close name 'Dialog_Close';

  //*
  //  Close - Closes a dialog.
  //
  //
  //  This routine will close the specified dialog.  A Terminate message
  //  will be sent to the ActionProc to allow clean up to occur before the
  //  dialog is destroyed.  If the user handles the Terminate message and
  //  returns True, this indicates that they wish for the dialog to continue
  //  execution and the Terminate is canceled.  If False is returned, this
  //  indicates that they are not going to override the Terminate and that
  //  the Terminate will proceed as usual.
  //
  //  CALLING SEQUENCE -
  //
  //    Close (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  function CreateModal
             (const dialogID   : cardinal;
              const dialogProc : DWSpec.ActionProc) : cardinal; stdcall;

  exports CreateModal name 'Dialog_CreateModal';

  //*
  //  CreateModal - Creates a Modal dialog.
  //
  //
  //  This routine is used to create a modal dialog and associate an
  //  ActionProc with that dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    status := CreateModal (dialogID, dialogProc)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The resource ID of the dialog box to create.
  //
  //    dialogProc : ActionProc
  //      The user supplied ActionProc for the dialog.
  //
  //  EXIT -
  //
  //    status : cardinal
  //      The dialogID of the displayed dialog.  Same as 'dialogID' is
  //      the first one, or a new ID.
  //




  function CreateModalExtra
             (const dialogID   : cardinal;
              const dialogProc : DWSpec.ActionProc;
              const extra      : pointer) : cardinal; stdcall;

  exports CreateModalExtra name 'Dialog_CreateModalExtra';

  //*
  //  CreateModalExtra - Creates a Modal dialog with extra data.
  //
  //
  //  This routine is used to create a modal dialog and associate an
  //  ActionProc with that dialog.  It also allows the address of some
  //  user defined extra data to be stored with the dialog.  The GetExtra
  //  routine may be called at any point in the ActionProc to retreive
  //  the address of the extra data.
  //
  //  CALLING SEQUENCE -
  //
  //    status := CreateModalExtra (dialogID, dialogProc, extra)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The resource ID of the dialog box to create.
  //
  //    dialogProc : ActionProc
  //      The user supplied ActionProc for the dialog.
  //
  //    extra : ADDRESS
  //      The address of the extra data to associate with the dialog.
  //
  //  EXIT -
  //
  //    status : cardinal
  //      The dialogID of the displayed dialog.  Same as 'dialogID' is
  //      the first one, or a new ID.
  //




  function CreateModeless
             (const dialogID   : cardinal;
              const dialogProc : DWSpec.ActionProc) : cardinal; stdcall;

  exports CreateModeless name 'Dialog_CreateModeless';

  //*
  //  CreateModeless - Creates a Modeless dialog.
  //
  //
  //  This routine is used to create a modeless dialog and associate an
  //  ActionProc with that dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    status := CreateModeless (dialogID, dialogProc)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The resource ID of the dialog box to create.
  //
  //    dialogProc : ActionProc
  //      The user supplied ActionProc for the dialog.
  //
  //  EXIT -
  //
  //    status : cardinal
  //      The dialogID of the displayed dialog.  Same as 'dialogID' is
  //      the first one, or a new ID.
  //




  function CreateModelessExtra
             (const dialogID   : cardinal;
              const dialogProc : DWSpec.ActionProc;
              const extra      : pointer) : cardinal; stdcall;

  exports CreateModelessExtra name 'Dialog_CreateModelessExtra';

  //*
  //  CreateModelessExtra - Creates a Modeless dialog with extra data.
  //
  //
  //  This routine is used to create a modeless dialog and associate an
  //  ActionProc with that dialog.  It also allows the address of some
  //  user defined extra data to be stored with the dialog.  The GetExtra
  //  routine may be called at any point in the ActionProc to retreive
  //  the address of the extra data.
  //
  //  CALLING SEQUENCE -
  //
  //    status := CreateModelessExtra (dialogID, dialogProc, extra)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The resource ID of the dialog box to create.
  //
  //    dialogProc : ActionProc
  //      The user supplied ActionProc for the dialog.
  //
  //    extra : ADDRESS
  //      The address of the extra data to associate with the dialog.
  //
  //  EXIT -
  //
  //    status : cardinal
  //      The dialogID of the displayed dialog.  Same as 'dialogID' is
  //      the first one, or a new ID.
  //




  procedure CreateDialogHandle
             (var   dHandle : DialogHandle); stdcall;

  exports CreateDialogHandle name 'Dialog_CreateDialogHandle';

  //*
  //  CreateDialogHandle - Creates a DialogHandle.
  //
  //  This routine is used to create a Dialog handle for a custom Dialog.
  //  Each custom Dialog should have its own Dialog handle.  The following
  //  routines can be called to change the attributes of a custom Dialog :
  //    SetCustomDialogExtra
  //    SetCustomDialogUserProc
  //
  //  CALLING SEQUENCE -
  //
  //    CreateDialogHandle (wHandle)
  //
  //  ENTRY -
  //
  //    None
  //      N/A
  //
  //  EXIT -
  //
  //    wHandle : DialogHandle
  //      A handle containing the styles and attributes of the custom
  //      Dialog.
  //




  procedure DestroyDialogHandle
             (var   dHandle : DialogHandle); stdcall;

  exports DestroyDialogHandle name 'Dialog_DestroyDialogHandle';

  //*
  //  DestroyDialogHandle - Destroys a DialogHandle.
  //
  //  This routine is used to destroy a Dialog handle which is no longer
  //  needed.
  //
  //  CALLING SEQUENCE -
  //
  //    DestroyDialogHandle (wHandle)
  //
  //  ENTRY -
  //
  //    wHandle : DialogHandle
  //      A handle containing the styles and attributes of the custom
  //      Dialog.
  //




  procedure SetCustomDialogUserProc
             (const dHandle  : DialogHandle;
              const UserProc : DWSpec.UserDlgProc); stdcall;

  exports SetCustomDialogUserProc name 'Dialog_SetCustomDialogUserProc';

  //*
  //  SetCustomDialogUserProc - Set up a procedure to handle raw Dialogs messages.
  //
  //  This routine will allow the user to set up a procecure for a custom
  //  Dialog which will handle raw Dialogs messages.  This procedure will be
  //  called each time the Dialog receives a message.  THIS IS not THE ONLY
  //  EVENT HANDLING procedure USED IN THE SYSTEM.  If a message is not
  //  handled by this procedure, simply return a value of false.
  //
  //  CALLING SEQUENCE -
  //
  //    SetSetCustomDialogUserProc (wHandle, userProc)
  //
  //  ENTRY -
  //
  //    dHandle : DialogHandle
  //      A handle containing the styles and attributes of the custom
  //      Dialog.
  //
  //    userProc : DWSpec.UserDlgProc
  //      The procedure to receive the raw Dialogs messages.
  //
  //      UserWndProc has the following parameters -
  //
  //        hwnd - Windows.HWND
  //          The Windows.HWND of the Dialog.
  //
  //        message - UINT
  //          The Dialog message.
  //
  //        wParam - Windows.WPARAM
  //          The Windows.WPARAM value passed in with the message.
  //
  //        lParam - Windows.LPARAM
  //          The Windows.LPARAM value passed in with the message.
  //
  //  EXIT -
  //
  //    bResult : BOOL
  //      The result to return for the message.  If this is returned
  //      as true, no further processing will be
  //      performed.
  //
  //      Some things to keep in mind when using a UserWndProc -
  //
  //        1.  Do not return a true value if you have not
  //            processed the message completely.
  //
  //  EXIT -
  //
  //    dHandle : DialogHandle
  //      A handle containing the styles and attributes of the custom
  //      Dialog including the new UserDlgProc.
  //




  procedure SetCustomDialogExtra
             (const dHandle    : DialogHandle;
              const extraBytes : pointer); stdcall;

  exports SetCustomDialogExtra name 'Dialog_SetCustomDialogExtra';

  //*
  //  SetCustomDialogExtra - Pass extra, private data for dialog's action and event procs.
  //
  //  This routine, used in conjunction with CreateCustomDialog,
  //  CreateDialogHandle, and DestroyDialogHandle, is a way to send extra
  //  data to the dialog procedures (which can be retrieved using
  //  GetCustomDialogExtra or GetExtra inside the scope of the dialog procs).
  //  This is a way to avoid global variables. It is an alternative to the
  //  CreateMod*Extra routines.
  //
  //  CALLING SEQUENCE -
  //
  //    SetCustomDialogExtra (wHandle, extraH)
  //
  //  ENTRY -
  //
  //    dHandle : DialogHandle
  //      A handle containing the styles and attributes of the custom
  //      Dialog.
  //
  //    extraBytes : pointer
  //      The address of the private, extra data to be made available
  //
  //  EXIT -
  //
  //    dHandle : DialogHandle
  //      A handle containing the styles and attributes of the custom
  //      Dialog including the extra Data.
  //




  procedure SetCustomDialogPropSheetFlag
             (const dHandle          : DialogHandle;
              const isPropSheet      : boolean;
              const isPropSheetModal : boolean); stdcall;

  exports SetCustomDialogPropSheetFlag name 'Dialog_SetCustomDialogPropSheetFlag';




  function CreateCustomDialog
             (const dHandle    : DialogHandle;
              const dialogID   : cardinal;
              const modal      : boolean;
              const dialogProc : DWSpec.ActionProc) : cardinal; stdcall;

  exports CreateCustomDialog name 'Dialog_CreateCustomDialog';




  function GetCustomDialogExtra
             (const Hwnd : Windows.Hwnd) : pointer; stdcall;

  exports GetCustomDialogExtra name 'Dialog_GetCustomDialogExtra';




  function CurrentDialogID
             (const msgData : pointer) : cardinal; stdcall;

  exports CurrentDialogID name 'Dialog_CurrentDialogID';

  //*
  //  CurrentDialogID - Retrieves the unique ID of a dialog.
  //
  //
  //  This routine will retrieve the unique ID of a dialog to which a message
  //  has been sent.  This will usually be the same number as the dialog's
  //  resource ID; however, if multiple instances of the same dialog exist
  //  simultaneously, then you will get a different, unique number for
  //  each additional instance.
  //
  //  CALLING SEQUENCE -
  //
  //    dialogID := CurrentDialogID (msgData)
  //
  //  ENTRY -
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    dialogID : cardinal
  //      The ID of the dialog receiving a message.
  //




  function GetOriginalDialogID
             (const dialogID : cardinal) : cardinal; stdcall;

  exports GetOriginalDialogID name 'Dialog_GetOriginalDialogID';

  //*
  //  GetOriginalDialogID - Retrieves the resource ID of a dialog.
  //
  //  Given the run-time assigned number of a dialog, this routine returns
  //  the resource ID that was used to create the dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    dialogID := OriginalDialogID (msgData)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The unique dialog ID for an instance of a dialog.
  //
  //  EXIT -
  //
  //    resourceID : cardinal
  //      The ID of the resource used to create the instance of the dialogID.
  //




  procedure Disable
             (const dialogID : cardinal); stdcall;

  exports Disable name 'Dialog_Disable';

  //*
  //  Disable - Disables a dialog.
  //
  //
  //  This routine will disable (prevent keyboard and mouse input) to
  //  the specified dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    Disable (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  procedure Enable
             (const dialogID : cardinal); stdcall;

  exports Enable name 'Dialog_Enable';

  //*
  //  Enable - Enables a dialog.
  //
  //
  //  This routine will enable the specified dialog.  This is the reverse
  //  of the Dialog.Disable procedure.
  //
  //  CALLING SEQUENCE -
  //
  //    Enable (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  procedure Flush
             (const dialogID : cardinal); stdcall;

  exports Flush name 'Dialog_Flush';

  //*
  //  Flush - Writes contents of all Sage controls to the current memory record.
  //
  //
  //  This routine will cause all Sage controls on the dialog which are linked
  //  to Sage tables and fields to have their contents written to the
  //  current memory record.  Note :  Sage controls are automatically written
  //  out when the dialog is terminated.
  //
  //  CALLING SEQUENCE -
  //
  //    Flush (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  function GetExtra
             (const dialogID : cardinal) : pointer; stdcall;

  exports GetExtra name 'Dialog_GetExtra';

  //*
  //  GetExtra - Retreives the extra information associated with a dialog.
  //
  //
  //  This routine will return the address of the extra information associated
  //  with the specified dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    extra := GetExtra (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //
  //  EXIT -
  //
  //    extra : ADDRESS
  //      The address of the extra information associated with this dialog.
  //




  procedure Hide
             (const dialogID : cardinal); stdcall;

  exports Hide name 'Dialog_Hide';

  //*
  //  Hide - Hides a dialog.
  //
  //
  //  This routine will hide the specified dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    Hide (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  function IsEnabled
             (const dialogID : cardinal) : boolean; stdcall;

  exports IsEnabled name 'Dialog_IsEnabled';

  //*
  //  IsEnabled - Checks to see if a dialog is enabled.
  //
  //
  //  This routine will determine whether a dialog is enabled (receives
  //  keyboard and mouse input) or is disabled.
  //
  //  CALLING SEQUENCE -
  //
  //    status := IsEnabled (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //
  //  EXIT -
  //
  //    status : boolean
  //      True if the dialog is enabled.
  //




  procedure Reset
             (const dialogID : cardinal); stdcall;

  exports Reset name 'Dialog_Reset';

  //*
  //  Reset - Causes all Sage controls to reload themselves from current memory record.
  //
  //
  //  This routine will cause all Sage controls on the dialog which are linked
  //  to Sage tables and fields to have their contents updated from the
  //  current memory record.  Note :  Sage controls are automatically loaded
  //  when the dialog is first created.
  //
  //  CALLING SEQUENCE -
  //
  //    Reset (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  procedure Redraw
             (const dialogID : cardinal); stdcall;

  exports Redraw name 'Dialog_Redraw';

  //*
  //  Redraw - Redraws a dialog.
  //
  //
  //  This routine will redraw the specified dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    Redraw (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  procedure SetFocus
             (const dialogID : cardinal); stdcall;

  exports SetFocus name 'Dialog_SetFocus';

  //*
  //  SetFocus - Sets to focus to a dialog.
  //
  //
  //  This routine will give focus to the specified dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    SetFocus (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  function SetParent
             (const childID     : cardinal;
              const newParentID : cardinal) : cardinal; stdcall;

  exports SetParent name 'Dialog_SetParent';

  //*
  //  SetParent - Assigns a parent to a child window or dialog by id.
  //
  //
  //  This procedure assigns a parent to a child window or dialog, and
  //  returns the ID of the previously assigned parent.  The child
  //  window or dialog must currently exist.  If the parent does not
  //  currently exist, the child will be made a top level window.
  //  Windows can be parents of both windows and dialogs, as can dialogs.
  //
  //  CALLING SEQUENCE -
  //
  //    oldID := SetParent (childID, parentID)
  //
  //  ENTRY -
  //
  //    childID : cardinal
  //      The ID of the child window or dialog.
  //
  //    parentID : cardinal
  //      The ID of the parent window or dialog.
  //
  //  EXIT -
  //
  //    oldID : cardinal
  //      The ID of the previous parent window or dialog.
  //




  procedure Show
             (const dialogID : cardinal); stdcall;

  exports Show name 'Dialog_Show';

  //*
  //  Show - Shows a dialog.
  //
  //
  //  This routine will show the specified dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    Show (dialogID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The ID of the dialog box.
  //




  function GetContextHelpControlID
             (const msgData : pointer) : cardinal; stdcall;

  exports GetContextHelpControlID name 'Dialog_GetContextHelpControlID';

  //*
  //  GetContextHelpControlID - Gets the ControlId pointed to by context help.
  //
  //  09/12/1996
  //
  //  This routine will return the ControlId pointed to by context help.
  //
  //  CALLING SEQUENCE -
  //
  //    controlID := GetContextHelpControlID (msgData)
  //
  //  ENTRY -
  //
  //    msgData : pointer
  //      The msgData passed in to the dialog proc.
  //
  //  EXIT -
  //
  //    controlID : cardinal
  //      The ID of the ControlId pointed to by context help.
  //




  function GetContextHelpID
             (const msgData : pointer) : cardinal; stdcall;

  exports GetContextHelpID name 'Dialog_GetContextHelpID';

  //*
  //  GetContextHelpID - Gets the helpId pointed to by context help.
  //
  //  09/12/1996
  //
  //  This routine will return the helpId pointed to by context help.
  //
  //  CALLING SEQUENCE -
  //
  //    helpID := GetContextHelpID (msgData)
  //
  //  ENTRY -
  //
  //    msgData : pointer
  //      The msgData passed in to the dialog proc.
  //
  //  EXIT -
  //
  //    helpID : cardinal
  //      The help ID pointed to by context help.
  //




  procedure SetContextHelpMsg
             (const helpID   : cardinal;
              const helpFile : array of char;
              const helpType : ContextHelpType;
              const msgData  : pointer); overload; stdcall;

  exports SetContextHelpMsg (const helpID   : cardinal;
                             const helpFile : array of char;
                             const helpType : ContextHelpType;
                             const msgData  : pointer) name 'Dialog_SetContextHelpMsg';

  //*
  //  SetContextHelpMsg - sets the Help message data.
  //
  //  09/12/1996
  //
  //  This routine will set the needed items for context help.
  //
  //  CALLING SEQUENCE -
  //
  //    SetContextHelpMsg (201, 'help.hlp', msgData)
  //
  //  ENTRY -
  //
  //    helpID : cardinal
  //      The ID of where to point in the help file.
  //
  //    helpFile : array of char
  //      The help file.
  //
  //    msgData : pointer
  //      The msgData passed in to the dialog proc.
  //
  //  EXIT -
  //
  //    None
  //      NOTES -  after calling this procedure make sure to set the
  //               exit flag to True  or if you are using ObjDialog
  //               then call 'ObjDialog.SetActionResponse (handle, True);'
  //               to set the flag true.  If this is not done no help
  //               will be displayed.
  //




  procedure SetContextHelpMsg
             (const helpID   : cardinal;
              const helpFile : string;
              const helpType : ContextHelpType;
              const msgData  : pointer); overload; stdcall;

  exports SetContextHelpMsg (const helpID   : cardinal;
                             const helpFile : string;
                             const helpType : ContextHelpType;
                             const msgData  : pointer) name 'Dialog_STRSetContextHelpMsg';

  //*
  //  STRSetContextHelpMsg - See documentation of SetContextHelpMsg.
  //




  procedure GetDialogPositionInfo
             (const dialogID     : cardinal;
              var   DialogXPos   : integer;
              var   DialogYPos   : integer;
              var   DialogWidth  : integer;
              var   DialogHeight : integer); stdcall;

  exports GetDialogPositionInfo name 'Dialog_GetDialogPositionInfo';

  //*
  //  GetDialogPositionInfo - Returns the position information on the specified dialog.
  //
  //
  //  This routine gets the position information for the specified dialog.
  //
  //  CALLING SEQUENCE -
  //
  //    GetDialogPositionInfo (DialogID, DialogXPos, DialogYPos,
  //                           DialogWidth, DialogHeight);
  //
  //  ENTRY -
  //
  //    DialogID : cardinal
  //      The ID of the window.
  //
  //  EXIT -
  //
  //    DialogXPos : cardinal
  //      The X position of the dialog.
  //
  //    DialogYPos : cardinal
  //      The Y position of the dialog.
  //
  //    DialogWidth : cardinal
  //      The width of the current dialog.
  //
  //    DialogHeight : cardinal
  //      The height of the current dialog.
  //




Send mail to   warren.merrill@inl.gov with questions or comments about this web site.
Copyright © 1989-2006 Battelle Energy Alliance