

The blog also has a lot of guidance teaching you how to get stated certain Microsoft technologies. This blog is about more than 50% telling you how to resolve error messages, especial for Microsoft products.

Since March 2011 Microsoft Live Spaces migrated to Wordpress () till now, I have is over 1 million viewers. You go to Product link then you will get the data below. Protected override async Task OnInitializedAsync()įorecasts = await PeopleService.GetProductAsync(DateTime.Now) Īdd link into NavMenu.razor under the Shared folder. The code as PeopleService (forecasts = null) Here I create a Blazor component named Product.razor.

Public void ConfigureServices(IServiceCollection services)Īdd a Blazor Component to your project under the Pages folder. You do not need to do this if you have follow the static data link above because the service would have been added. Task task = Task.FromResult(productModels) Īdd PeopleService to Startup.cs. ProductModel.ProductName = dr.ToString() SqlDataReader dr = command.ExecuteReader() opening connection and executing the query SqlCommand command = new SqlCommand(sql, conn) String sql = “Select TOP 5 ProductName, UnitPrice From Products” SqlConnection conn = new SqlConnection(strConn) Database=Northwind Trusted_Connection=True ” ProductModel productModel = new ProductModel() ProductModel productModels = new ProductModel Public Task GetProductAsync(DateTime startDate) add Blazor Component to display the data.Ĭreate a service class name PeopleService in Data folder to populate data. Just that in the service part you need to connect to database. This article showing you how to add the database into the Blazor page.It is pretty much the same like the static data.
