Plant Modeling: Remove Alphabetical Sorting in CNS Editor

Back to All Topics


There is a tool inside of WinCC OA that allows you to model your plant. The plant model editor tool can be used for building and modifying data structures based on common name service (CNS). Therefore, views and trees can be created and used in the project efficiently.

The tool has a default sort that automatically sorts your model by alphabetical order. This may not be helpful if you need to present a different order. This technical tutorial will show you how to turn off the default sort in the tree view.

WinCC OA Common Name Service (CNS) Modeling

To change this you will have to modify the function “cnsTree_repaintTree”.

  1. Open the cnsTree.ctl located in the library 3.16 project directory > library > cnsTree.ctl
  1. Search for the line “sTreeObject.setSorting(CNS_TREE_COLUMN_ID, TRUE);”
  2. Comment it out by adding “//” at the front of the line.
WinCC OA .ctl editing
Was this article helpful?
How can we improve this article?
Scroll to Top