function talking to table storage

Copper Contributor

Hi folks, am new to the microsoft universe and have a real hard time getting started with functions.

Want to use a C# CloudTable client in order to read, write, update and delete to a table I created in a storage account. But somehow I don't figure out on what packages to use in function.proj file.

 

I am using the portal for developing the Function and currently got the function.proj setup like below but also tried other things since I found various versions out on the net...

 

 

<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="RestSharp" Version="106.6.8"/>
<PackageReference Include="Microsoft.Azure.Storage.Common" Version="11.1.1" />
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Storage" Version="3.0.10" />
</ItemGroup>

</Project>

 

 

in the runc.csx I put 

 

 

using Microsoft.Azure.Storage.Common;
using Microsoft.Azure.WebJobs.Extensions.Storage;

 

to import it. But somehow it is nor working...I keep getting error when building a StorageAccount client telling my referencing is wrong...
 
Is a nuget package missing or do I have to import them in a different way? for RestSharp it works fine...? anybody can lend me a hand? Thanks!
0 Replies