|
pfc_addall
|
|
Full name
|
pfc_u_tvs.pfc_addall
|
Access
|
public
|
Extend of
|
long
|
Return value
|
long
|
Prototype
|
event long pfc_addall(long,n_ds)
|
Name
|
Datatype
|
ll_count
|
long
|
ll_row
|
Long
|
ll_rowcount
|
Long
|
event pfc_addall;//////////////////////////////////////////////////////////////////////////////
//
// Event: pfc_AddAll
//
// Arguments:
// al_parent The handle to the Treeview item to place data under
// ads_source data source to use for setting treeview item values
//
// Returns: long
// number of items added successfully
// 0 = no items added
// -1 = an error occurred
//
// Description: Add all the rows from data source to the treeview.
//
//////////////////////////////////////////////////////////////////////////////
//
// Revision History
//
// Version
// 6.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.
//
//////////////////////////////////////////////////////////////////////////////
long ll_count=0
Long ll_rowcount, ll_row
// check the arguments
If IsNull(ads_source) or Not IsValid(ads_source) Then Return -1
If (al_parent < 0) or isnull(al_parent) then Return -1
// loop through the data and add the items
ll_rowcount = ads_source.RowCount()
For ll_row = 1 to ll_rowcount
If this.event pfc_insertitem(al_parent, ads_source, ll_row, INSERT_LAST, 0) < 1 then
Return -1
End If
ll_count++
End For
return ll_count
end event
Name
|
Owner
|
datastore.rowcount |
datastore
|
systemfunctions.isnull |
systemfunctions
|
systemfunctions.isvalid |
systemfunctions
|
pfc_u_tvs.pfc_insertitem |
pfc_u_tvs
|