BBjFileInfo::getCurrentKeyName

Description

In BBj 6.0 and higher, this BBjFileInfo method gets the name of the current VKEYED key chain.

Syntax

Return Value

Method

string

getCurrentKeyName()

Parameters

None.

Return Value

The name associated with the current key chain.

Remarks

This method throws an !ERROR=13 if the file associated with this BBjFileInfo object is not a VKEYED file, or if there is no name associated with the current key chain.

Example

rem ' Get the name of the current VKEYED key chain

filename$ = "Sample.dat"
erase filename$,err=*next
vkeyed filename$,[1:1:6]+[2:1:3],[3:1:2],0,64
channel = unt
open (channel)filename$
BBjFileInfo! = BBjAPI().getFileSystem().getFileInfo(channel)
BBjFileInfo!.setKeyName(0,"OrderNumber")
BBjFileInfo!.setKeyName(1,"Salesperson")
print "Current Key Name: ",BBjFileInfo!.getCurrentKeyName()
end

See Also

BBjAPI

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