小编Ali*_*Ali的帖子

JobStorage.Current 属性值尚未初始化。您必须在使用 Hangfire Client 或 Server API 之前设置它

我在 mvc 应用程序中使用 hangfire。我正在向用户发送预约提醒。我已经在我的应用程序中安装了 hangfire。我已经在 startup.cs 类中配置了 hangfire。但是当我运行该应用程序时,它会产生以下错误 JobStorage。当前属性值尚未初始化。您必须在使用 Hangfire Client 或 Server API 之前设置它。

using Hangfire;
using Hangfire.SqlServer;
using Microsoft.Owin;
using Owin;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using UKC.Data.Infrastructure;
using UKC.UI.Helper;

[assembly: OwinStartup(typeof(UKC.UI.App_Start.Startup))]
namespace UKC.UI.App_Start
{
    public partial class Startup
    {
        public void Configuration(IAppBuilder app)
        {
            ConfigureAuth(app);
            GlobalConfiguration.Configuration
               .UseSqlServerStorage("DbEntities");

            app.UseHangfireDashboard();
            app.UseHangfireServer();

        }
    }
}
Run Code Online (Sandbox Code Playgroud)

c# asp.net-mvc hangfire

9
推荐指数
4
解决办法
1万
查看次数

当前的.NET SDK不支持定位.NET Core 2.2

我正在使用asp.net core 2.2。我正在使用Visual Studio 2017.当我创建.net core Web应用程序时,界面提示错误,当前的SDK不支持以.net core 2.2为目标?当我转到项目属性时,在目标框架列表中没有目标框架.net core 2.2吗?

c# asp.net-core

5
推荐指数
1
解决办法
2654
查看次数

标签 统计

c# ×2

asp.net-core ×1

asp.net-mvc ×1

hangfire ×1