Esempio n. 1
0
    private IServiceResolver GetResolver(string name)
    {
        ResolverBuilder resolverBuilder = new ResolverBuilder();

        resolverBuilder.Build();
        IServiceResolver serviceResolver = resolverBuilder.GetResolver();

        serviceResolver.AppName = name;

        return(serviceResolver);
    }
Esempio n. 2
0
    public void Application_Start(object sender, EventArgs e)
    {
        //Initialize NEP Application
        NepServiceApplication.Init();

        WebApiConfig.Register(GlobalConfiguration.Configuration);

        // Code that runs on application startup
        CMS.AMS.ResolverBuilder resolver = new ResolverBuilder();
        CurrentRequest.Resolver         = resolver.GetResolver();
        CurrentRequest.Resolver.AppName = "Global.asax";
        IDBAccess         m_dbaccess = CurrentRequest.Resolver.Resolve <DBAccess>();
        SQLParametersList paramlist  = new SQLParametersList();
        String            QueryStr   = "Update Folders set MassOperationStatus = '~FNIU~'";

        m_dbaccess.ExecuteNonQuery(DataBases.LogixRT, CommandType.Text, QueryStr, paramlist);

        //Adding health monitors
        InitializeHealthMonitors();
        HealthOptions.AddHealthMonitors(componentHealthMonitors.ToArray());
    }