Skip to content

TResourceTreeNode.FindFreeID

Find a free ID to be used as a resource name

Declaration

Source position: resourcetree.pp line 65

public 
function TResourceTreeNode.FindFreeID(aType: TResourceDesc) : TResID
                                     ;  virtual;

Description

This method is used to find an available ID to be used as a name for a resource, given a resource type. It is used internally by AddAutoID method of TResources.

Remark:

This method should only be called on root nodes (instances of TRootResTreeNode).

Errors

If there are no free ids left for the given resource type, an ENoMoreFreeIDsException is raised.