Contact Info

Crumbtrail

ActiveXperts.com » Support » Network Monitor » KB Article

 

Q6650010: Can I use the Configration API in CShare.NET?

Yes you can. To do so, please use the following steps:

  • Launch Microsoft Visual Studio;
  • Open your VB.NET project, or create a new one;
  • Add a ActiveXperts API reference to your project: choose 'Add Reference‚Ķ' in your Solution Explorerer, select the 'COM' tab and select 'ActiveXperts Network Monitor API'. It will add the 'Interop.AXNMCFGLib' interop to your Project References;
  • In your code, add the following 'Using' statement:
    using AXNMCFGLib;
  • Declare and create a new Network Monitor Config object like this:
    NMConfig objNMConfig = new NMConfig();

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using AXNMCFGLib;

namespace ConsoleApplication1
{
  class Program
  {
    static void Main(string[] args)
    {
      NMConfig objNMConfig = new NMConfig(); // Create instance of COM Object

      Console.WriteLine("ActiveXperts Network Monitor API {0}\nBuild: {1}\nModule: {2}\n", 
                         objNMConfig.Version, objNMConfig.Build, objNMConfig.Module );
    }
  }
}
(viewed: 331)