BBjAppServer::updateApplicationIcon

Description

In BBj 12.0 and higher, this method updates the contents of the icon given by url to contain the contents of the file given by iconFileName.

Syntax

Return Value

Method

void

updateApplicationIcon(BBjResourceUrl url, string iconFileName)

Parameters

Variable

Description

url

A BBjResourceUrl with MIME type image/* (e.g. image/png).

iconFileName

The file containing the new contents for the given icon.

Return Value

None.

Remarks

When this method returns, BBjResourceUrl::getAppUrl will have changed. Uses of this string outside the BBjAppServer classes will require updating with the new URL value.

Example

rem ' BBjAppServer::updateApplicationIcon

admin! = bbjapi().getAdmin("admin","admin123")
appServer! = admin!.getWebAppServer()
vector! = appServer!.getStaticResources()
if (vector!.size()) then
    for i = 0 to vector!.size() - 1
        resource! = vector!.get(i)
        print ""
        print resource!.getMimeType()
        print resource!.getSourceFileName()
        print resource!.getAppUrl()
        if (resource!.getMimeType().startsWith("image/")) then
            appServer!.updateApplicationIcon(resource!, resource!.getSourceFileName())
        endif
    next i
endif

See Also

BBjAPI

BBjAppServer

BBjAppServer::addApplicationIcon

See the BBj Object Diagram for an illustration of the relationship between BBj Objects.