Connection Information

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Connection Type

AddToLibraryList – PB Docs 2019 – PowerBuilder Library

AddToLibraryList – PB Docs 2019

AddToLibraryList

PowerScript function

Description

Adds new files to the library search path of an application or
component at runtime.

Syntax

Argument

Description

filelist

A comma-separated list of file names. Specify the full
file name with its extension. If you do not specify a path,
PowerBuilder uses the system’s search path to find the
file.

Return value

Integer.

Returns 1 if it succeeds. If an error occurs, it returns:

-1 — The application or component is being run in the PowerBuilder
development environment, rather than from a standalone executable or
server.

-2 — The new library list or existing library list is empty, or
another internal error has occurred.

Usage

When an application needs to load an object, PowerBuilder searches
for the object first in the executable file and then in the dynamic
libraries specified for the application. For a deployed component,
PowerBuilder searches the PBD files in the component’s library list. You
can specify additional library files with AddToLibraryList.

Calling AddToLibraryList appends a new list of files, in the order
in which they are specified in filelist, to the list of library files
specified in the target. If filelist contains a file name that is already
in the library list, that file name is not added to the library list. If
filelist contains more than one occurrence of a given file name, the first
occurrence is added to the library list.

PowerBuilder cannot check whether the libraries you specify are
appropriate for the application. It is up to you to make sure the
libraries contain the objects that the application or component
needs.

This function has no effect in the PowerBuilder development
environment.

Examples

This example adds different PBDs to the library search path
depending on whether product or customer processing is to be
performed:

See also

GetLibraryList

SetLibraryList


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x