The method GetAccessRule is used to read a configured access rule from the function block.
The rule configuration to be read is specified by a rule index. As the function block can store up to 30 rule configurations, the values allowed for the rule index are 1...30.
|
Inputs / Outputs |
Data type |
Description |
|---|---|---|
|
i_uiRuleIndex |
UINT |
Index of the rule to be read. Value range: 1...30 |
|
iq_stRuleConfig |
Configuration parameter of the rule that is read. The linked instance of the structure is initialized when the method is executed. |
|
Data type |
Description |
|---|---|
|
The return value indicates the result of the method. If the value is ET_Result.Ok, the execution of the method was completed successfully. |
|
Return value |
Possible cause |
Solution |
|---|---|---|
|
ET_Result.NoRule |
No rule is configured at the specified rule index. |
Verify the number of configured rules using the property NumberOfConfiguredAccessRules. The number of configured rules is equal to the greatest possible rule index for this method. |
|
ET_Result.InvalidInput |
The value of i_uiRuleIndex is invalid. |
Verify whether the value of i_uiRuleIndex is within the range 1...30. |