Not able to build sample api source code for Batch execution service ( C#, R, Python) RRS feed

  • Question

  • using Microsoft.WindowsAzure.Storage;
    using Microsoft.WindowsAzure.Storage.Auth;
    using Microsoft.WindowsAzure.Storage.Blob;]]

    Not able to reference.   I am using Visual studio 2015, Target .Net 4.5.2...  This is a sample code for Batech execution API for a Azure Predictive Model. I am using this to build a console app for testing the model.  I have followed steps required to run this app in Visual studio except I am not able to reference azure storage. I am not find it getting listed in the reference manager.. 

    Let me know what I am missing.. 

    Getting Build error.. 

    Severity Code Description Project File Line Suppression State
    Error CS0234 The type or namespace name 'Storage' does not exist in the namespace 'Microsoft.WindowsAzure' (are you missing an assembly reference?) FEpredictionapp C:\Users\suma\Documents\Visual Studio 2015\Projects\ConsoleApplication3\ConsoleApplication3\tmlmodelapp.cs 24 Active

    Monday, April 10, 2017 1:55 AM

All replies

  • It seems you have not installed the required nuget package for accessing Storage. Azure Storage can be included in your application by installing "Azure Storage" nuget package.  ONce its installed you will get reference to storage.

    Nuget is the recommended way for connecting to azure storage. https://www.nuget.org/packages/WindowsAzure.Storage/

    Right click on your solution root(from solution explorer), manage nuget packages and then install the above package. Once installe the package, which will automatically add the reference too. Then compile and find the missing namespaces code and Vstudio can help to automatically insert the namespace. 

    Vishnu VG

    • Edited by 1-----------1 Monday, April 10, 2017 6:49 AM
    • Proposed as answer by Md Shihab Saturday, April 15, 2017 6:02 PM
    Monday, April 10, 2017 6:44 AM
  • Thanks Vishnu.  azure storage  8.1.1 is installed.   The reference does't azure storage. in the list. ..

    Monday, April 10, 2017 9:01 AM
  • Thanks Vishnu.  azure storage  8.1.1 is installed.   The reference does't show azure storage. in the list. ..
    Monday, April 10, 2017 9:01 AM
  • installing azure storage 5.0.4 preview version helped.
    Monday, April 10, 2017 3:09 PM
  • sorry it was azure storage 5.0.3 preview
    Monday, April 10, 2017 3:10 PM