title: How to access .NET classes within Powershell?
body: <p>I am new in the Powershell and Azure (C/C++ background) world and I want to write a PowerShell script which monitors an Azure Event Hub. One way (and so far the only way I've found) to solve this is by using the .NET classes from <code>Microsoft.​Azure.​Event​Hubs.​Processor</code>. I assume the code to create an instance of the <code>EventProcessorHost</code> class would look something like this: </p>
  
  <pre><code>$eventPHost = [Microsoft.Azure.EventHubs.Processor]::EventProcessorHost($AZR_EVENT_HUB_PATH, $AZR_CONSUMER_GRP_NAME, $AZR_EVENT_HUB_CONNECTION_STR, $AZR_STORAGE_CONNECTION_STR, $AZR_LEASE_CONTAINER_NAME);
  </code></pre>
  
  <p>However, the namespace <code>Microsoft.Azure.EventHubs.Processor</code> is unknown to PowerShell and it seems that I am doing something wrong or missing something. At this point I am not sure if my code is invalid or I am missing some .NET SDK or something. Also I couldn't find any examples which are similar to this. </p>
  
  <p>Could anyone lead me in the right direction please? I am kind of stuck with no idea in which direction to go. </p>