Code Walkthrough - Agilent Technologies X Series Startup Manual

Measurement applications for modular instruments
Hide thumbs Also See for X Series:
Table of Contents

Advertisement

Code Walkthrough

Open a session to the M9000 Resource Manager.
1.
OpenM9000Session
try
{
_myM9000Session = SessionFactory.OpenM9000Session();
}
catch (Exception e)
{
Console.WriteLine("Could not start M9000Session (details
follow).");
Console.WriteLine(e.ToString());
WaitForUser();
Cleanup();
return 1;
}
Console.WriteLine("M9000Core sucessfully started.");
Create a sharable M9391 IVI driver session.
2.
OpenSharableResource
// Open the IVI driver as a sharable resource
var result =
_myM9000Session.OpenSharableResource(ResourcePluginType,
_iviAlias, out _resourceName, simulate);
if (result != ResourceManagerResult.Ok)
{
Console.WriteLine("Could not open sharable resource of type
'" + ResourcePluginType
+ "' using alias '"
result.ToString() + ".
WaitForUser();
Cleanup();
return 2;
}
41
X-Series Measurement Applications for Modular Instruments Startup Guide
+ _iviAlias + "'. \n" +
See Windows Event Log.");

Advertisement

Table of Contents
loading

This manual is also suitable for:

M90xaM9391aM9393a

Table of Contents