Skip to content

Latest commit

 

History

History
63 lines (50 loc) · 1.63 KB

File metadata and controls

63 lines (50 loc) · 1.63 KB

BuildResourceListN

Description

Build a resource list from the specified file.

FUNCTION BuildResourceListN(
				type         : INTEGER;
				fullPath     : DYNARRAY[] of CHAR;
				VAR numItems : LONGINT): LONGINT;
def vs.BuildResourceListN(type, fullPath):
    return (LONGINT, numItems)

Parameters

Name Type Description
type INTEGER the type of resource to put in the list
fullPath DYNARRAY[] of CHAR The path to the file that provides the resources.
numItems LONGINT the number of items in the list built

Remarks

_c_, (2016.02.29): It supports also posix paths on mac ("/"). It can't be used to retrive the resources in the active document.

Here some usage examples:

resID := 127; { wall styles }
pathID := 113; { Wall ~ Slabs folder }
path := Concat(GetFolderPath(pathID), 'Walls~Slabs Styles Metric.vwx'); { pick a file within the shipped default content }

list := BuildResourceListN(resID, path, cnt); { chosen document }
list := BuildResourceListN2(resID, GetFPathName, cnt); { WARNING: it always returns zero }

Examples

BEGIN
	ResourceListID := BuildResourceListN(rType,rPath,NumResSyms);
END; {PROCEDURE BuildSymbolList}
import vs

# Build a resource list from the specified file.
type = 0
fullPath = 'C:/Temp'

resultN, numItems = vs.BuildResourceListN(type, fullPath)
vs.Message('BuildResourceListN returned: ' + str((resultN, numItems)))

See Also

VS Functions: BuildResourceList

Version

Availability: from Vectorworks 2013

Category