Release 10.1A: OpenEdge Development:
Programming Interfaces

> ## Avoiding common HLC errors

> To ensure compatibility between your HLC functions and Progress, consider the following when writing your functions:

> - An HLC library function does not always return character and decimal data as null-terminated strings. For example, the `pvar` parameter of the `prordc()` function contains character data without null termination. To terminate such a string with the null character, you must add it yourself.

> - When you check the value of a field or variable that HLC returns, check for the Unknown value (`?`). The field might not always contain a valid value.

> - If you return from your top-level function without setting an appropriate return code value, Progress might raise an error condition unexpectedly. See the "Returning error codes from a top-level function" section section for more information.

> - Use the `promsgd()` HLC library function to display messages directly to the terminal. Using the standard C function `printf()` might produce unexpected results when used to send raw data to a terminal.

Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095