Klicke hier für den deutschen Artikel.
Introduction
The LlOptions
enumeration in List & Label offers an easy way to set options in a clear and structured way. But what if an option is not included in this enumeration? This article explains why this is the case, where to find such options and how you can still set them.
Which options are meant by this, among other things?
Why are not all options included?
There are several reasons why certain options are not included in the LlOptions
enumeration:
- Compatibility options: Some options are used to ensure compatibility with older versions. These are rarely needed and could affect the clarity of the enumeration.
- Rarely used options: Some options are only relevant in special scenarios and are not needed by most users.
- Clarity: The
LlOptions
enumeration should remain easy to understand and manageable. Too many entries could make it unnecessarily difficult to use.
Where can you find such options?
These additional options are defined in the documentation or directly in the C++ header files of List & Label. There they are usually provided with a #define
macro that sets the numeric value of the option.
Example from a C++ header file:
#define LL_OPTION_COMPAT_ZUGFERDXMLPATH_PREVIEWEMBEDDING (423) /*default: false*/
This is the option LL_OPTION_COMPAT_ZUGFERDXMLPATH_PREVIEWEMBEDDING
that has the numeric value 423
. The comment shows that the default value for this option is set to false
.
How do you set these options?
Even if the option is not included in the LlOptions
enumeration, it can be set for integer values using the overloading of LlSetOption
.
Syntax:
LlSetOption(int optionId, int value);
Example:
// Setting the option LL_OPTION_COMPAT_ZUGFERDXMLPATH_PREVIEWEMBEDDING (423)
using combit.ListLabel30; // change namespace according to version
var ll = new ListLabel();
ll.Core.LlSetOption(423, 1); // Sets the option to "true"
Summary
- Why not in the enumeration? Compatibility reasons, rarely used options and to maintain clarity.
- Where to find it? In the documentation or the C++ header files in the List & Label installation directory (…\combit\LL?? \Examples\Visual C++).
How to set? Using theLlSetOption(int optionId, int value)
.
This flexibility allows you to make specific settings that are not explicitly listed in the LlOptions
enumeration. This keeps the API both powerful and clear.