2

I've created a simple Azure Bot Function that works fine when ran in Azure. I have installed the required SDK's but when I download/copy the solution locally (Windows 10 using VS 2017) and then run "dotnet restore" followed by "debughost.cmd" I get the following error:

Function compilation error ... error CS0234: The type or namespace name 'Bot' does not exist in the namespace 'Microsoft' (are you missing an assembly reference?)

How do I manage the dependencies? The solution has no "References" folder and "Manage NuGet Packages for Solution..." is grayed out.

Is this a VS 2017 problem? I don't have VS 2015 currently installed.

Thanks, TK

Terrence
  • 21
  • 3

1 Answers1

4

I got probably the same issue and managed to fix it by adding the reference to Bot Connector in the project.json. You need to do another dotnet restore after.

{
  "frameworks": {
    "net46":{
      "dependencies": {
        "Microsoft.Bot.Builder.Azure": "3.2.1",
        "Microsoft.Bot.Connector": "1.1.0"
      }
    }
   }
}

Thanks, Dini

Dini
  • 111
  • 3