Escaping the @ Symbol in an MVC View
I’ve been working with OData recently and one thing that briefly stumped me was that the property names begin with @ and in an MVC view the @ symbol is used to indicate C# code so when I tried to Read more…
I’ve been working with OData recently and one thing that briefly stumped me was that the property names begin with @ and in an MVC view the @ symbol is used to indicate C# code so when I tried to Read more…
If you want to use Entity Framework to access pre-existing SQL tables (the database first approach) then providing they’re all keyed up correctly it’s possible to generate all the required classes and the DB context for them with just a Read more…
When creating a console application I normally mimic ASP.NET core apps and keep my configuration settings in an appsettings.json file. When publishing the application in Visual Studio the appsettings.json file needs to have it’s properties updated to ensure it’s copied Read more…
IdentityServer4 is an OpenID Connect and OAuth 2.0 framework for ASP.NET Core which acts as a middleware layer for managing authentication and authorization. Configuration data for the IdentityServer4 service can be persisted in a variety of storage mediums including Microsoft Read more…
File C:\Users\AppData\Roaming\npm\func.ps1 cannot be loaded. The file C:\Users\AppData\Roaming\npm\func.ps1 is not digitally signed. You cannot run this script on the current system. For more information about running scripts and setting execution policy, see about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170. If you’re recieving the above Read more…
There are various ways of authenticating against Azure Functions but the default method is by providing a code value as a URL parameter in the call to the endpoint. If you’re using RestSharp to call your function there’s no specific Read more…
In the v3 version of Azure Functions DI is better supported and there’s now some offical documentation demonstrating how it’s done. It’s pretty similar to how it was done previously, below is updated code from my previous v2 example. The Read more…
I’ve been using IAsyncEnumerable recently for the streaming of SQL query rows and of deserialized objects from API calls and while it seems to work like a charm it does seem to have a few configuration issues. Firstly, on creating Read more…
Outputting a SQL table to a CSV file on an SFTP site is pretty much the same as outputting it to a local CSV file but with the added step of using SSH.NET to upload the stream. Full code for Read more…
This post demonstrates how write a SQL table out to a local CSV file, the full code for this can be found here. GetSqlRowsAsync This returns an IAsyncEnumerable of DataRows, IAsyncEnumerable has been newly introduced with C# 8.0 and it Read more…