Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

SetEnableResourceTracking

NI LabWindows™/CVI™ 2009 Help

Edition Date: November 2009

Part Number: 370051P-01

»View Product Info

int SetEnableResourceTracking (int newState);

Purpose

Enables and disables resource tracking in the current thread.

Note Note   This function is available only in the LabWindows/CVI Full Development System.

Resource tracking is available at both the extended and standard debugging levels. When you enable resource tracking, LabWindows/CVI tracks resources such as memory blocks, file handles, and panel handles that you allocate in your program. Selecting Extended as the Debugging level in the Debugging Options section of the Build Options dialog box enables resource tracking by default. LabWindows/CVI displays currently allocated and recently released resources in the Resource Tracking window. If you select Standard as the Debugging level in the Build Options dialog box, you must use this function to enable resource tracking. You also can use the GetEnabledResourceTracking function to detect whether resource tracking is enabled.

Note Note  RT On RT targets, leaked resources persist until you reboot the target. However, the Resource Tracking window displays only leaked resources from the most recent program execution.

Display the Resource Tracking window by selecting Resource Tracking in the Window menu.

Parameters

Input
Name Type Description
newState int Determines whether resource tracking is enabled or disabled.

Pass a nonzero value to enable. Pass zero to disable.

Return Value

Name Type Description
previousState int Indicates if resource tracking was enabled previously.

Code Description
1 Previously enabled.
0 Previously disabled or not available.

Additional Information

Library: Utility Library

Include file: utility.h

LabWindows/CVI compatibility: LabWindows/CVI 9.0 and later


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit