pbSuppressCacheError - cDbCJGrid
Determines if the grid should report an error when a grid cache error occurs
Type: Property
Access: Read/Write
Data Type: Boolean
Parameters: None
Syntax
Property Boolean pbSuppressCacheError
| Access Type | Syntax |
|---|---|
| Read Access: | Get pbSuppressCacheError to BooleanVariable |
| Write Access: | Set pbSuppressCacheError to BooleanVariable/Value |
Description
Determines if the grid should report a handled error when a grid cache error occurs (i.e., when a record in the grid cache has been deleted or changed on the back end such that it can no longer be re-read).
The default value is True, so the handled errors are normally suppressed.
Suppressing re-read errors in grids is probably the best default for end-users using a deployed application. Real world, multi user conditions arise where a row cannot be re-read and providing an error message (even a handled one) to an end-user serves little purpose. The automatic grid refresh recovery process works well. When a row cannot be re-read the grid's refresh process will rebuild the grid with valid records. Having this preceded by an error message somewhat defeats the automatic recovery.
A downside of suppressing cache errors is that may suppress actual programming errors. For testing purposes developers can set this property to False and then remove it upon deployment. They can also place a breakpoint in HandleCacheError or SetGridCacheError and wait for the code to get executed. If you work with dynamic constraints, this is probably something you want to do when testing your application.
Since most developers create class layers, you can set pbSuppressCacheError in your sub-class to whatever you want. Our advice will be to leave it True (suppress the handled error) because that is what is best for a deployed application.