Configuring Glimpse SQL Tab with N-Layer Architecture

六月ゝ 毕业季﹏ 提交于 2020-01-24 20:15:30

问题


I know it's often question regarding disabled SQL tab in Glimpse but I really can't make it work. I have N projects in Solution. Web and Database are seperated. I installed:

Glimpse, Glimpse.EF6, Glimpse.MVC, Glimpse.Ado to Web project, but nothing seems work. I even tried to use GlimpseDbConnection in DbContext - still no result.

public CemaDbContext() : base(cemaDbContextConnection, true)
        {
        }

        private static GlimpseDbConnection cemaDbContextConnection
        {
            get
            {
                var contextSection = ConfigurationManager.ConnectionStrings["ManagerConnection"].ConnectionString;
                return new GlimpseDbConnection(new SqlConnection(contextSection));
            }
        }

Maybe somebody can guide me thru how to setup SQL Tab?


回答1:


Seems that problem was very stupid. I tried to test Glimpse SQL tab with Elmah and not with actual data that was posted or received. When I created View with form with simple data post SQL TAB start working.



来源:https://stackoverflow.com/questions/39500420/configuring-glimpse-sql-tab-with-n-layer-architecture

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!