pfc_findnext


pfcapsrv.pbl   >   pfc_n_cst_rtefind   >   pfc_findnext   

Full name pfc_n_cst_rtefind.pfc_findnext
Access public
Extend of integer
Return value integer
Prototype event integer pfc_findnext(n_cst_findattrib)

Name Datatype
No Data

Name Datatype
lb_forward boolean
li_rc integer

event pfc_findnext;//////////////////////////////////////////////////////////////////////////////
//
//	Event:  				pfc_findnext
//
//	Arguments:
//	anv_findattrib		nvo-structure - reference of search attributes
//
//	Returns:  			long
//							search results
//
//	Description:  		This event is called dynamically to start the search
//							using the current settings.
//
//////////////////////////////////////////////////////////////////////////////
//	
//	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
boolean	lb_forward

If (IsNull(idw_requestor) Or Not IsValid(idw_requestor)) And &
	(IsNull(irte_requestor) Or Not IsValid(irte_requestor)) Then
	Return -1
End If

If ib_ongoingfind Then
	//Determine if this continues to be an Ongoing Find. 
	ib_ongoingfind = of_IsOnGoingFind(anv_findattrib)
End If

//Get a copy of passed attributes.
inv_findattrib = anv_findattrib

//Set up direction.
lb_forward = (Not Lower(inv_findattrib.is_direction)='up')

//Determine if this is the first find or an ongoing find.
if ib_ongoingfind THEN
	//On going find.
	If IsValid(irte_requestor) Then
		li_rc = irte_requestor.findnext()
	Else
		li_rc = idw_requestor.findnext()
	End If
Else
	//First time find.
	If IsValid(irte_requestor) Then
		li_rc = irte_requestor.find (	inv_findattrib.is_find, lb_forward, &
								not inv_findattrib.ib_matchcase, &
								inv_findattrib.ib_wholeword, True)
	Else
		li_rc = idw_requestor.find (	inv_findattrib.is_find, lb_forward, &
								not inv_findattrib.ib_matchcase, &
								inv_findattrib.ib_wholeword, True)
	End If	
end if

//Determine if the next find/replace could be a FindNext operation.
ib_ongoingfind = (li_rc > 0) 

return li_rc

end event

     
Name Owner
No Data

     
Name Owner
datawindow.find datawindow
datawindow.findnext datawindow
richtextedit.find richtextedit
richtextedit.findnext richtextedit
systemfunctions.isnull systemfunctions
systemfunctions.isvalid systemfunctions
systemfunctions.lower systemfunctions
pfc_n_cst_rtefind.of_isongoingfind pfc_n_cst_rtefind

     
Full name
No Data

     
Name Scope
No Data