of_logondlg


pfcapsrv.pbl   >   pfc_n_cst_appmanager   >   of_logondlg   

Full name pfc_n_cst_appmanager.of_logondlg
Access public
Extend of integer
Return value integer
Prototype public function integer of_logondlg()

Name Datatype
No Data

Name Datatype
lnv_logonattrib n_cst_logonattrib

public function integer of_logondlg ();//////////////////////////////////////////////////////////////////////////////
//
//	Function:  of_LogonDlg
//
//	Access:  public
//
//	Arguments:  none
//
//	Returns:  integer
//	 1 = successful logon
//	 0 = User cancelled from the logon dialog
//	-1 = an error occurred opening the logon window
//
//	Description:  Obtain a User ID and password from the user
//
//////////////////////////////////////////////////////////////////////////////
//
//	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.
//
//////////////////////////////////////////////////////////////////////////////

n_cst_logonattrib	lnv_logonattrib

//////////////////////////////////////////////////////////////////////////////
// Load logon object values
//////////////////////////////////////////////////////////////////////////////
this.event pfc_prelogondlg (lnv_logonattrib)

//////////////////////////////////////////////////////////////////////////////
// Open logon window
//////////////////////////////////////////////////////////////////////////////
if OpenWithParm (w_logon, lnv_logonattrib) < 0 then
	return -1
end if

//////////////////////////////////////////////////////////////////////////////
// Get return logon object
//////////////////////////////////////////////////////////////////////////////
lnv_logonattrib = message.powerobjectparm

//////////////////////////////////////////////////////////////////////////////
// Store user id
//////////////////////////////////////////////////////////////////////////////
if Len (lnv_logonattrib.is_userid) > 0 then
	if of_IsRegistryAvailable() then
		RegistrySet (is_userkey + "\logon", "userid", lnv_logonattrib.is_userid)
	else
		SetProfileString (is_userinifile, "logon", "userid", lnv_logonattrib.is_userid)
	end if

	of_SetUserID (lnv_logonattrib.is_userid)
end if

return lnv_logonattrib.ii_rc

end function

     
Name Owner
No Data

     
Name Owner
systemfunctions.len systemfunctions
systemfunctions.openwithparm systemfunctions
systemfunctions.registryset systemfunctions
systemfunctions.setprofilestring systemfunctions
pfc_n_cst_appmanager.of_isregistryavailable pfc_n_cst_appmanager
pfc_n_cst_appmanager.of_setuserid pfc_n_cst_appmanager
pfc_n_cst_appmanager.pfc_prelogondlg pfc_n_cst_appmanager

     
Full name
w_logon
demopfc

     
Name Scope
No Data