ade_qllistctgy

Land Desktop Development ARX CPP SDK

Up a level
ade_qllistctgy
 
 

Lists the query category IDs.

struct resbuf*

ade_qllistctgy();

Returns a list of category IDs, or, if there are no categories or an error occurs, NULL.

You must release the resbuf.

The following sample parses the resbuf returned by ade_qllistctgy() and prints a list of query category ID's. Then it releases the resbuf, as required.

struct resbuf* pQueryCategoryListRb = NULL;
pQueryCategoryListRb = ade_qllistctgy();
if (NULL != pQueryCategoryListRb) {
    int nQueryCategories = 0;
    struct resbuf* rb = pQueryCategoryListRb;
    while(rb != NULL) {
        ++nQueryCategories;
        acutPrintf(
            "\nQuery category %d has the Id: %.0lf",
            nQueryCategories, rb->resval.rreal);
        rb = rb->rbnext;
    }
}
else {
    acutPrintf(
        "\nThere are no query categories in this project.");
}
acutRelRb(pQueryCategoryListRb);