Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

Hull and Outfitting

The Drawing Tasks

  • Last UpdatedNov 06, 2025
  • 3 minute read

These tasks operate on a specific drawing. In the sample drawing templates, there is a single drawing task that formats the Drawing Number by calling the PML function !!assyDrwgNo(!array).

The task contains six arguments and corresponding values;

Argument Description

Example Value

Use the Name Sequence database

‘NO’

Attribute that will hold the Drawing Number

DRWGN

Prefix String

AVEVA

Suffix String

AD

Start Index Number

0001

Separator Character

' ' (space)

When the PML function is called, it will set the DRWG attribute DRWGN to a string value calculated using the parameters 3 to 6. This will result in a drawing number which can be output in the drawing title block using the hash code #DRWGN on the backing sheet. An example string is shown below.

Note:
The value 2.1.1 is extracted from the ASMBLY attribute ASNAME.

The index number calculation is handled by checking the current index number set in all drawings within the current MDB in order to determine the next unused one.

Please note that if you create a large number of Assembly Drawings in the same MDB, then the search for the next unique drawing number might be slow and performance could be seriously compromised. To avoid this, when there are a large number of existing drawings, AVEVA recommends the use of the Name Sequence database for determining the drawing number.

The PML function also includes an example of how you might create an index number by utilizing a Name Sequence database (NSEQ). In this case, a unique index value is extracted from the database across sessions and irrespective of which MDB the user is located. This is more foolproof than the previously discussed method.

The extracted number uses the unique identifier 'ASSEMBLYADP', so you should avoid using this when extracting other numbers from the same Name Sequence Database, but if you wish to change it then you will need to replace the two places where this word appears in the PML function.

To use this method, you must modify the drawing template task parameters as follows; set Argument 1 to 'YES' and Argument 5 to a value such as '0', which will be incremented to produce '1' as the first value. The PML function will subsequently add any leading zeros as required to produce an index number in the format '0001'.

You will want to modify the Task and the PML function to suit your projects and company standards. For example, if you wish to change the leading zeros you will need to modify the section in the PML function that tests the length of the resulting index from the name sequence database.

Or, if you wish to produce a drawing number with a different format then depending on which method described above for extracting an index number you chose to use, you will need to modify the function where the drawing number is built up using the combination of prefix, separator, assembly name, leading zeros, index number and suffix.

For full details of how to organize a Name Sequence database, please refer to Sequence Number Generator.'

Related Links
TitleResults for “How to create a CRG?”Also Available in