开发者

Visual studio winform designer shows design errors as text rather than html [duplicate]

开发者 https://www.devze.com 2022-12-24 06:13 出处:网络
This question already has answers here: Closed 12 years ago. 开发者_运维问答 Possible Duplicate: VS2005 Winforms Designer Exception Screen and IE8
This question already has answers here: Closed 12 years ago. 开发者_运维问答

Possible Duplicate:

VS2005 Winforms Designer Exception Screen and IE8

All of the sudden, visual studio displays designer errors as plain html text, for example:

<DIV id="div1" class="ErrorStyle" width="100%"><span style="font-weight: 600"><br>Object reference not set to an instance of an object. </span><br><a href=""

instead of displaying the usual html formatted. I haven't been able to find anything similar to it on google.

Before getting this problem, when I tried opening the winform designer, I would get the run/save/cancel dialog of internet explorer for a .tmp file, instead of the designer window. That went away when I found out that I had notepad assigned to the .tmp file type and removed that.

Any ideas how to fix this?


A quick workaround is to modify the registry settings.

HKEY_LOCAL_MACHINE\SOFTWARE\Classes

Add a key called .tmp to this.

Then, add the following strings:

(Default)     REG_SZ    htmlfile
Content Type  REG_SZ    text/html
PerceivedType REG_SZ    text

And that should do it.


This is due to IE8. Others with this problem have been able to fix it by reverting to IE7. I have not tried that my self.

  • VS2005 Winforms Designer Exception Screen and IE8
  • VS2005 with WinXP: Designer's Error Page shows html Code

EDIT: I've posted an answer on a duplicate stackoverflow question.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号