Navigation: Scripting Reference Manual > Functions & Subroutines > PrefsGetARNRetainCount

 

PrefsGetARNRetainCount

 

Contact Us: fredsupport@photonengr.com

 

Description

This command retrieves the "Number of ARNs to retain (-1=keep all)" preferences value (Miscellaneous tab of the Preferences dialog in the GUI).  Depending on their "CalcTiming" parameter, Detector Entities can auto-create analysis results nodes (ARNs) on the object tree. To prevent the un-intended build-up of ARNs, this preference specifies the number of unlocked ARN(s) to retain in the Analysis Results folder prior to the creation of new ARNs. The check is triggered when a raytrace is issued.

 

 

Syntax

numArns = PrefsGetArnRetainCount()

 

 

Parameters

numArns (Long)

Returned number of unlocked ARNs which will be retained in the Analysis Results folder.  A value of -1 indicates that all ARNs should be retained.

 

 

Example

The following example retrieves the current ARN preference setting and resets the preference value.

 

Sub Main

 

    Dim numArns As Long

    numArns = PrefsGetARNRetainCount()

    If numArns > 0 Then

        numArns = -1

        PrefsSetARNRetainCount numArns

    End If

 

End Sub

 

 

See Also

Miscellaneous and Preference Commands

 

 

 

 

 

Copyright © Photon Engineering, LLC