ClassID ID Description Comments
3 55 Load the top level entries The command loads IDs and contents of the products. The command also returns the ID of the panel statement used to load the subentries. The statement may contain information about the labels of the search fields.
3 >= 10000 Load the subentries Command to load subentries
18 95 Load the ID of the script to be executed at Double click of a product.

The following mechanism is used to load the products in the Treeview:

  1. Load the top level products with panel statement 55. This (and only this) statement evaluates the search criteria .
  2. Each object of each level is given a Panelstatement ID >= 10000, which can be used to load the subentries.
  3. An entry cannot be further expanded if the panel statement for the subentries is 0.

The actual load command depends on the type of data connection. ODBC connections expect an SQL SELECT statement, XML data pools a XML SELECT statement, SOAP connections expect a getProductList statement.

Only Panelstatement 55 (top) level evaluates the search input, so only this statement has input values that must be marked with ? in the command. The following entries are expected.

Parameter Index Type Description Remarks
2 string Content of the first search field with % appended Standard search only. For further search criteria see here.
3 Content of the second search field with % appended
4 int rownum < ... Always replaced by 100 (only ODBC connections)

All commands use the same scheme for return values.

Column

normal/ SOAP getList

Parameter Type Description Remarks
1 1 ID int Unique ID of the data. über die ID des Datensatzes wird der Status (+, x, ....) der Produkte in der Palette gesetzt.
2 2 ID2
3 3 ID3
4 - StringID char* StringID of the data NOT ON SOAP CONNECTIONS (When using SOAP, use row 17 for the StringID)

For using StringIDs, the following conditions have to be fulfilled:

  1. Definition of the table attribute Hasstringids in the table panelstatements or definition of the XML element Hasstringids in panelstatements.xml, see StringIDs
  2. In the definition of the panel statement, the value of Hasstringids must be = 1.
5 4 classID int internal ClassID of the object Currently unused
6 5 iconID int Number of the Icon to be used for the object
2000 2001 2002 2003 2004
2005 2006 2007 2008 2009
2010 2011 2012 2013 2014
2015 2016 2017 2018 2019
2020 2021 2022 2023 2024
2025 2026 2027 2028 2029
2030 2031 2032 2033 2034
2035 2036 2037 2038 2039
2040 2041 2042 2043 2044
2045 2046 2047 2048 2049
2050 2051 2022 2053 2054
2055 2056 2057 2058 2059
2060 2061 2062 2063 2064
2065 2066 2067 2068 2069
2070 2071 2072 2073 2074
2075 2076 2077 2078 2079
2080 2081 2082 2083 2084
2085 2086 2087 2088 2089
2090 2091 2092 2093 2094
2095 2096 2097 2098 2099

2200

2201
7 6 1. column of the palette string values shown in the palette list
8 7 2. column of the palette
9 8 forceDelete int Object status

>0 : If the object is not planned in the document, it is not included in the product list. If the object is scheduled in the document, it will be deleted from the list if all references to this product are removed from the document.

0 : Normal scheduled product

<0 : The object should not be planned in the document. The link button is deactivated and the object is not checked when checking the status with .

10 9 panelStatementID int >= 10000, reference to a panel statement of the same type, which can be used to load the subentries. If the value is 0, the object cannot be expanded any further.

  • The following returns are optional (except for SOAP calls to getProductList and products with StringIDs) and will be used for the product setup.

  • If the parameters in the top level statement (usually the panel statement 55 or a FindStatement) return these parameters, all statements for loading the subentries must also fill the parameters.

  • When calling the SOAP method getProductList and using StringIDs, the parameters must be specified. If necessary, set their values to 0 or "".
11 10 docID int ID of the document The parameter is currently unused and can be filled with 0.
12 11 masterpage string Pattern page name in the form Prefix name (e.g. "C-Double page") If a new page has to be created for this product during product construction, the specified sample page is used. If the sample page does not exist or if the specification is empty, the standard page of the structure is used.

The specification is only relevant for grid-oriented product construction. In the page template-based structure, sample pages are assigned via the page templates.

13 12 Reserved string Enter the value "" here.
14 13 Own_Icon string Icon description "" or Definition of an own icon for the entry. If the field is not empty, the specification iconID from column 6 (or 5 for SOAP) will be ignored.
15 14 pagetemplateID int Before building the product, create a new page with Pagetemplate create

0 or valid ID of a pagetemplates. In the palette, the name of the pagetemplates separated by @ after the template name is displayed:

    Template@Pagetemplate

Use this option carefully: By specifying a pagetemplates the product will automatically be created on a new page during product creation.

16 15 Reserved int Enter the value 0 here.
17 16 pageItemID int Template with which the product should be inserted

Templates are determined page by page: If the given template is limited to left pages but has a specification for a right-sided template, the right-sided template is automatically used on right pages.

If the specification is 0 or the specified template does not exist, the standard template of the structure will be used.

- 17 stringID string StringID of the product ONLY SOAP

For the StringID to be used, the following two conditions must be met :

  1. Definition of the table attribute hasstringids in the table panelstatements resp. Definition of the XML element hasstringids in the file panelstatements.xml, see StringIDs
  2. In the definition of the panel statement the value of hasstringids must be set to 1.

The commands support the full set of panel statement tags such as <user>, <now>. You can find a complete list of these variables here.

To allow access to the values of the parent objects when loading subentries, a number of additional variables are supported in the statements for loading these objects.

Name Type Description Comments
parent.ID int ID of the parent record With parent.parent the parent record of the parent record is referenced, etc.
parent.ID2
parent.ID3
parent.StringID string
parent.classID int internal ClassID of the parent record
parent.Row1 string List text of parent record
parent.Row2
parent.ForceDelete int Forcedelete value of parent record

In addition, you can access the current values in the search fields of the palette at any level. The figure shows the tags assigned to the search fields. If a search field is empty, the tag gets the value "%", otherwise exactly the content of the search field (i.e. not converted to capital letters).

The statements have the same columns for database and XML and for main and subentries, with the only difference that under XML and for all subentries (database and XML) the order of ClassID and IconID is reversed : ... IconID, ClassID, ...

To rename search fields or to assign them at startup use the mechanism described here.

From version 1.4.2 R 504 the entries of the product research can be provided with own icons. The following table gives a complete list of all supported sources:

Keyword source Description Transparency Example
ImagePath

local file system

Complete path to the image file

The path may begin with the valid alias name for folder.

none

ImagePath: "$DESKTOP/../.././InDesign/Plugins/Pictures/aaa.png"

IconPath

White

ImageURL

Network

Valid URL to image file

none

ImageURL : "http://www.hi13.de/tantarantana.jpg"

IconURL

White

SOAPImage Current SOAP connection

fieldID an image file of the SOAP service

There must be a SOAP connection.

none

SOAPImage : "icons/123"

SOAPIcon

White

Caution : In all cases there must be a space before and after the colon.

images are automatically scaled to be fully visible. Images that are not PNG will be scaled versions of the images stored on your computer: 

    $PREFS/Werk [2]/CS_VERSION/ProductPreviews/17x 17/...     with CS_VERSION equal CS6 for ID CS6, CS7 for ID CC, CS8 for ID CC 2014 etc.

This folder or any entries of these folders may be deleted - then previews will be created automatically if required. But files of these folders must not be changed. The images, even if they have known image formats, are not readable by other graphics programs.

To ensure that icons are always visible on the scalable gray of the Illustratir user interface, different icons must be used for light and dark surfaces. It will automatically try to find image files with the following name extension :

If the required variants are not found, the base file is used without an additional name extension.

The transparency of different UI colors can of course no longer be white-based. For transparencies, always use PNG images with alpha channel. In this case, the image or icon specification is equivalent. Here is a sample image with the same colors as the Comet icons:

    

As path separator you can use / or \ systemindependent.

When using \ as a path separator, please remember that this character must be masked with \, as is usual in strings, i.e. it must be specified as \\. Since most programs for processing database contents also expect \ to be doubled if you want to pass it in a insert or update, you must in most cases pass all \ as \\\\:
when defining the search statement.
    select
     1, 0, 0, a.id,
    3,
     2020,
    anbsp;label, '''',
    0,
    10000,
    0,
      A-Sample Template''',
      ''',
       "ImagePath. "
\\\\Users\\\\paul\\\\Desktop/../../InDesign/Plugins/Bilder/buffer.png"'',
    0,
    0,
    0
    from comet_container a, comet_planningtypes r
   where a.container_id=''0'' and a.active = 1 and r.keyname = a.type_name
   order by sort, label

Whether you need to mask the character when defining the search statement for the database or not (so whether you need to write \\ or \\\\), you need to test it with your input program. If you perform the search in the product search, the statement is written to the log file, where all path separators should appear as \\. If you still don't get a single image, the path doesn't point to a readable image.

Here are two examples of SQL and XML.

First the panel statement 55 to load the objects of the first layer.

select ID, 1401, 1702, ''
   3, -- unused
 2012, -- House
   Num, name,
   ForceDelete,
   10000, -- Load the subentries
   0, '',
   '', '', 0, 0,
   7 -- Template 7
from WIIProducts
   where ID > ?
      and upper (num) like ?
      and upper (name) like ?
      and rownum < ?

Load the second layer objects.

select ID, <parent.ID>, 123 ,'',
   2009, -- Gear
   ObjectType, 
   Name, Value, ForceDelete,
   10001, -- Load the subentries
   0, '',
   '', '', 0, 0,
   7 -- Template 7
from WIIElements
where productID = <parent.ID>

union

select ID, <parent.ID>, 123, '',
   2010, -- No passing
   ObjectType,
   Name, Value, ForceDelete,
   10001,
   0, '',
   '', '', 0, 0,
   7 -- Template 7
from WIIElements2
where productID = <parent.ID>
		
union

select ID, <parent.ID>, 123, '',
   2011, -- Heart
   ObjectType,
   Name, Value, ForceDelete,
   10001,
  
   0, '',
   '', '', 0, 0,
   7 -- Template 7
from WIIElements3
where productID = <parent.ID>'

Load the third layer objects.

select 1, 1401, 1702, '',
   2003, -- Incandescent lamp
   -1,
   '||to_char(<parent.ID>),
   <parent.Row2>||' '|| to_char(<parent.ID2>),
   0,
   0, -- No more subentries
   0, '',
   '', '', 0, 0,
   7 -- Template 7
from dual

union

select 1, 1401, 1702, '',
    2002, -- Book with pen
   -1,
   '|| to_char(<parent.ID>),
   <parent.Row2>||' '|| to_char(<parent.ID2>),
   0,
   0, -- No more subentries
 0, '',
   '', '', 0, 0,
   7 -- Template 7
from dual

The instructions for XML are given analogously to the panel statements for databases. Only the following differences have to be considered :

  1. In order to simulate the SQL statement union, several panel statements with the same ID can be defined. These statements are executed one after the other. The entry usage of the panel statements is used as sorting.
  2. The file specification for the XML command can be a value defined in the file datafiles.xml or in the plugin Datafiles. To refer to a defined (and enabled) data file, enter the alias name of the data file with $ at the beginning.

This is an example entry that supports StringIDs. The orange parts return a StringId. The return value of id is automatically converted to a string. In order to load the subentries of the products found in this way, a definition for the panel statement 10001 must also be made.

<panelstatement>
    <id> 10000>?
    <usage>1</usage>
    <domain>
    <statement>
        "$MYFILE"
        select id, &lt;parent.ID&gt;, 123, id
            objecttype,
            2009,
            name, value, forcedelete,
            10001,
            docid,
            masterpage,
            grid.name, grid.elem, grid.id, grid.elemid,
            pageitemid
        node elements.element
        where productid = &lt;parent.ID&gt;
    </statement>
    <in_parameters></in_parameters>
    <out_parameters></out_parameters>
    <description>Load subentries</description>
    <hasstringids>1</hasstringids>
</panelstatement>

SOAP services must provide a special command to load (sub)product lists. You can find a complete description of the SOAP service here. On the plugin page of the SOAP connection getProductList is used in four different ways :

  1. getProductList Load the top level products.
  2. getProductList1 Download the top level products. String parameters are not enclosed in quotation marks.
  3. getSubProductList Load the subentries of a product
  4. getProductList Load the subentries of a product. String parameters are not enclosed in quotation marks.

The following example shows a valid SOAP statement to load the top-level products (Panelstatement 55) :

<panelstatement>
   <id>55</id>
   <usage>Download product research products as a treeview>
   <domain> <domain>/domain>
   <statement>
      getProductList id > ? and name like ? and num LIKE ?
   </statement>
   <in_parameters></in_parameters>
   <out_parameters></out_parameters>
   <description></description>
</panelstatement>
Unlike the database connection and XML data statements described above, the SOAP statement getProductList does not allow you to specify which panel statement to use to load the subentries. This setting is made on the server side. For example, if the server returns 20000, the panel statement entry might look like this:
<panelstatement>
   <id>20000</id>
   <usage>Load subproducts SOAP</usage>
   <domain> <domain>/domain>
   <statement>
      getSubProductList id = <parent.ID>
   </statement>
   <in_parameters></in_parameters>
   <out_parameters></out_parameters>
   <description></description>
</panelstatement>

The entries on the list can react to double clicks. The action to be performed is defined as follows:

  1. With the help of panel statement 95 an action ID is assigned to the product. The statement must provide an integer and can take up to four input values (int, int, int, varchar) which get replaced by the current product ID. In the statement in addition to the commonly used tags like <ID>, <ID2>, <folder> the tag <depth> is defined; it contains the (0-based) level of the product.
  2. If an action ID is defined (>0) the action is evaluated as a script. In the script an additional global variable gClicked is defined which contains the 0-based line number of the entry.

Here are some examples of valid panel statements which can be used to define a valid double click ID.

select 900+<depth> from dual;

"datafiles.xml"                        -- any XML file
select 900+<depth>

select id%3 from ... where ID = ?       
select id%3 from ... where ID = <ID>   -- ? are optional

And here a simple double click script

int main ()
{
	showmessage ("Row %d, ID = %d",
			gClicked+1,
			gRecordID);
	return 1;
}

Placeholders of texts and frames can be linked to the respective product by Shift-click in the first column of the product list. The placeholders of all selected frames and/or texts are linked to the product. If the so-called autoload button of the palette is activated (red)

    

all placeholders will be loaded immediately after linking.

The palette has the ClassID 3