Skip to main content
Version: Next

METHOD Get attribute

METHOD Get attribute ( path ; attribType {; *} ) : Boolean

ParameterTypeDescription
pathTextPath of project method
attribTypeIntegerType of attribute to get
*OperatorIf passed = command applies to host database when executed from a component (parameter ignored outside of this context)
Function resultBooleanTrue = attribute selected; otherwise False

This command is not thread-safe, it cannot be used in preemptive code.

Description

The METHOD Get attribute command returns the value of the attribType attribute for the project method designated by the path parameter. This command only works with project methods. If you pass an invalid path, an error is generated.

In the attribType parameter, pass a value indicating the type of attribute to get. You can use the following constants, found in the Design Object Access theme:

ConstantTypeValueComment
Attribute executed on serverInteger8Corresponds to the "Execute on server" option
Attribute invisibleInteger1Corresponds to the "Invisible" option
Attribute published SOAPInteger3Corresponds to the "Offered as a Web Service" option
Attribute published SQLInteger7Corresponds to the "Available through SQL" option
Attribute published WebInteger2Corresponds to the "Available through 4D HTML tags and URLs (4DACTION...)" option
Attribute published WSDLInteger4Corresponds to the "Published in WSDL" option
Attribute sharedInteger5Corresponds to the "Shared by components and host database" option

If the command is executed from a component, it applies by default to the component methods. If you pass the * parameter, it accesses the methods of the host database.

The command returns True when an attribute is selected and False if it is deselected.

See also

METHOD SET ATTRIBUTE