of_processmessage


pfcapsrv.pbl   >   pfc_n_cst_error   >   of_processmessage   

Full name pfc_n_cst_error.of_processmessage
Access protected
Extend of integer
Return value integer
Prototype protected function integer of_processmessage()

Name Datatype
No Data

Name Datatype
li_rc Integer
li_testrc Integer

protected function integer of_processmessage ();//////////////////////////////////////////////////////////////////////////////
//
//	Function:  		of_ProcessMessage
//
//	Access:  		protected
//
//	Arguments: 		None.
//
//	Returns:  		integer
//						The button returned from the message window.
//						-1 if an error was encountered.
//
//	Description:  This function is called to process the Message.
//
//////////////////////////////////////////////////////////////////////////////
//
//	Revision History
//
//	Version
//	5.0   Initial version
//
//////////////////////////////////////////////////////////////////////////////
//
//	Copyright © 1996-1997 Sybase, Inc. and its subsidiaries.  All rights reserved.
//	Any distribution of the PowerBuilder Foundation Classes (PFC)
//	source code by other than Sybase, Inc. and its subsidiaries is prohibited.
//
//////////////////////////////////////////////////////////////////////////////

Integer	li_rc
Integer	li_testrc

// Set other information.
inv_errorpass.idt_date = DateTime(today(), now())

// As appropriate, run the attended/unattended process.
If ib_unattended Then
	// Set the Default button as the return button for unattended mode.
	inv_errorpass.ii_buttonclicked = inv_errorpass.ii_default
	li_rc = inv_errorpass.ii_default
Else
	// Attended Mode.  Open response window.	
	Choose Case ii_style
		Case 	0
				inv_errorpass.ii_buttonclicked = of_MessageBox('pfc_errorsrv_msg', &
						inv_errorpass.is_title, &
						inv_errorpass.is_text, inv_errorpass.ie_icon, &
						inv_errorpass.ie_buttonstyle, inv_errorpass.ii_default)
		Case	1
				// Set the timeout option.
				inv_errorpass.ii_timeout = ii_timeout
		
				If ib_beep Then
					beep(1)
				End If
				li_testrc = OpenWithParm(w_message, inv_errorpass)
				If  li_testrc > 0 Then
					// Get the structure passed by the response window for 
					// any user input and buttonclicked.
					If IsValid(Message.powerobjectparm) Then
						inv_errorpass = Message.powerobjectparm
					End If			
				End If
	End Choose
End If

// If appropriate, log the error.
If (inv_errorpass.ii_severity >= ii_logseverity) Then
	li_testrc = of_ProcessLog ()
End If

// If appropriate, send a notification.
If (inv_errorpass.ii_severity >= ii_notifyseverity) Then 
	li_testrc = of_ProcessNotify()
End If

Return inv_errorpass.ii_buttonclicked
end function

     
Name Owner
pfc_n_cst_error.of_message pfc_n_cst_error
pfc_n_cst_error.of_message pfc_n_cst_error

     
Name Owner
systemfunctions.beep systemfunctions
systemfunctions.datetime systemfunctions
systemfunctions.isvalid systemfunctions
systemfunctions.now systemfunctions
systemfunctions.openwithparm systemfunctions
systemfunctions.today systemfunctions
pfc_n_cst_error.of_processnotify pfc_n_cst_error
pfc_n_cst_error.of_processlog pfc_n_cst_error
pfc_n_base.of_messagebox pfc_n_base

     
Full name
w_message
demopfc

     
Name Scope
No Data