Note: This page includes content based on the F1 documentation for Centura development. It may be partially converted to support APF development, but should be regarded to be of uncertain actuality. It is provided as is. Eventually, it should be replaced by documentation available from within Visual Studio.
Const.PM_DataSourceCreateWindow
Applications and the framework send the Const.PM_DataSourceCreateWindow message to data source to initialize data transfer and then create a window.
Name | Description |
---|---|
nWhat = wParam | Standard method parameter. Possible values are Const.METHOD_Inquire, Const.METHOD_Execute, Const.METHOD_GetType |
sWindow = SalNumberToHString( lParam ) | Name of window to start. The window may not have any window parameters. |
When nWhat = Const.METHOD_Inquire, TRUE is returned if the window is registered in the application and the corresponding data source is available to the current user.
When nWhat = Const.METHOD_Execute, TRUE is returned if the window is successfully created, FALSE otherwise..
When processing the Const.PM_DataSourceCreateWindow message, the framework automatically calls the DataSourcePrepareKeyTransfer method to initialize the DataTransfer object with all key items. Applications may override DataSourcePrepareKeyTransfer to initialize DataTransfer in a different way.
It is important not to confuse the Const.PM_DataSourceCreateWindow message with the Const.PM_StartWindow message which is sent to the MDI window to start a window without using data transfer.
This menu item uses the Const.PM_DataSourceCreateWindow message create the History Log window.
Menu Item: Show &History… Keyboard Accelerator: (none) Status Text: Show update history for the current object Menu Settings Enabled when: SalSendMsg( hWndForm, PM_DataSourceCreateWindow, METHOD_Inquire, SalHStringToNumber( 'frmHistoryLog' ) ) Checked when: Menu Actions Call SalPostMsg( hWndForm, PM_DataSourceCreateWindow, METHOD_Execute, SalHStringToNumber( 'frmHistoryLog' ) )private SalNumber menuItem__View_MenuActions() { Int.PostMessage(Sys.hWndForm, Const.PM_DataSourceCreateWindow,
Const.METHOD_Execute, "frmDeferredDetail"); return 0; }