0
我已經通過nuget將Ninject Mvc Extensions添加到我的項目中,並且已將NinjectMVC3文件放入App_Start文件夾。如果我進入我的源代碼,「No available source」頁面出現在我的面前。Ninject引導程序沒有可用的源代碼
問題是我無法訪問代碼行的下一步。我必須在自己的代碼中找到下一步並放置斷點。
它正在尋找NinjectDependencyResolver.cs,但在當前路徑中沒有這樣的文件,因爲它已在下面的信息中顯示。
以下是來自Visual Studio的源文件信息。
Locating source for 'c:\Projects\Ninject\Maintenance2.2\ninject.web.mvc\mvc3\src\Ninject.Web.Mvc\NinjectDependencyResolver.cs'. Checksum: MD5 {c4 f8 b4 46 45 cb f8 1c c7 74 29 b9 70 9f 2b 24}
The file 'c:\Projects\Ninject\Maintenance2.2\ninject.web.mvc\mvc3\src\Ninject.Web.Mvc\NinjectDependencyResolver.cs' does not exist.
Looking in script documents for 'c:\Projects\Ninject\Maintenance2.2\ninject.web.mvc\mvc3\src\Ninject.Web.Mvc\NinjectDependencyResolver.cs'...
Looking in the projects for 'c:\Projects\Ninject\Maintenance2.2\ninject.web.mvc\mvc3\src\Ninject.Web.Mvc\NinjectDependencyResolver.cs'.
The file was not found in a project.
Looking in directory 'C:\Program Files\Microsoft Visual Studio 10.0\VC\crt\src\'...
Looking in directory 'C:\Program Files\Microsoft Visual Studio 10.0\VC\atlmfc\src\mfc\'...
Looking in directory 'C:\Program Files\Microsoft Visual Studio 10.0\VC\atlmfc\src\atl\'...
Looking in directory 'C:\Program Files\Microsoft Visual Studio 10.0\VC\atlmf敤楦楮楴湯祜畯摲晥湩瑩'...
The debug source files settings for the active solution indicate that the debugger will not ask the user to find the file: c:\Projects\Ninject\Maintenance2.2\ninject.web.mvc\mvc3\src\Ninject.Web.Mvc\NinjectDependencyResolver.cs.
The debugger could not locate the source file 'c:\Projects\Ninject\Maintenance2.2\ninject.web.mvc\mvc3\src\Ninject.Web.Mvc\NinjectDependencyResolver.cs'.
我該如何擺脫這個問題?
我解釋了爲什麼它是編輯問題中的一個問題 – AnyOne
您可以打開堆棧跟蹤窗口,查看堆棧中的內容,然後雙擊您感興趣的堆棧幀。然後將斷點放在您需要的行中代碼靠近這個堆棧幀。 –