[英]How can I change the exception messages in Vs2012?
開個玩笑(大約六個月前),我在同事的PC上更改了異常文件,這樣當拋出NullReferenceException
時,他會得到一個有趣的“麻煩射擊技巧”,並提及他-我們在開玩笑在他的地下室里砍...
在忘記了這個錯誤之后(現在是6個月),出現了此錯誤,雖然是有趣的,但也需要修復並改回它。
有什么想法我會改回來嗎? 還是應該是什么文件? 我所有的谷歌搜索似乎都指向文件異常。
(對於那奇怪的樣子...)
包含VS2012的自定義疑難解答提示的文件是:
C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\ExceptionAssistantContent\1033\DefaultContent.xml
這是NullReferenceException
塊的外觀:
<Exception>
<Type>System.NullReferenceException</Type>
<Tip HelpID="EHNullReference">
<Description>Use the "new" keyword to create an object instance.</Description>
</Tip>
</Exception>
<Exception>
<Type>System.NullReferenceException</Type>
<Tip HelpID="EHNullReference">
<Description>Check to determine if the object is null before calling the method.</Description>
</Tip>
</Exception>
惡作劇的榮譽,我必須記住那個!
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.