Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

ParseResource

I have used the following line to get a list of resources so I can identify the serial ports on a machine and have a user select the appropriate port.
ResourceManager.GetLocalManager().ParseResource(resource,out interfaceType,out interfaceNumber,out resourceClass,out expandedName,out userAlias);
 
This works fine on my desktop installation but fails to work when I run the code on my laptop.  In the latter case, the userAlias is an empty string.
Is there something that needs to be turned/initialised, that I have overlooked?
0 Kudos
Message 1 of 2
(3,185 Views)
Hi hardwired,

The last string parameter in this prototype is called aliasIfExists.  The empty string returned might mean that the alias hasn't been defined for that resource.  Here is the quick description in the Help:
aliasIfExists
Upon return, contains the user-defined alias for the given resource.

Gavin Fox
Systems Software
National Instruments
0 Kudos
Message 2 of 2
(3,169 Views)