944,027 Members | Top Members by Rank

Ad:
  • C# Discussion Thread
  • Unsolved
  • Views: 12233
  • C# RSS
Dec 5th, 2004
0

C# XML Comment Problems

Expand Post »
I am working through the book Visual C#.NET Step by Step, and I came to the section of the book where the author shows how to create comments on your code with XML.

///<summary>
///The obligatory Hello World in C#
///</summary>
///<remarks>
///This program writes out Hello World
///using the WriteLine method of the
///System.Console class.
///</remarks>

This is the code the author gives. You can use Visual Studio to Build Comment Web Pages, but none of the XML (specifically the things between the summary and remarks tags) show up. Is there something wrong with my version of VC#.NET?
I can't even get my browser to view XML created webpages. If I click on one of those orange XML boxes that are on some webpages, all I get is the XML coding. Is this suppose to happen? Am I missing something?
Similar Threads
Reputation Points: 12
Solved Threads: 0
Newbie Poster
Brent_Ritterbec is offline Offline
24 posts
since Aug 2004
Dec 6th, 2004
0

Re: C# XML Comment Problems

this is a great stuff to imorove our knowledge
Reputation Points: 10
Solved Threads: 0
Newbie Poster
onlykannan2000 is offline Offline
1 posts
since Dec 2004
May 9th, 2005
0

Re: C# XML Comment Problems

Quote originally posted by Brent_Ritterbec ...
I am working through the book Visual C#.NET Step by Step, and I came to the section of the book where the author shows how to create comments on your code with XML.

///<summary>
///The obligatory Hello World in C#
///</summary>
///<remarks>
///This program writes out Hello World
///using the WriteLine method of the
///System.Console class.
///</remarks>

This is the code the author gives. You can use Visual Studio to Build Comment Web Pages, but none of the XML (specifically the things between the summary and remarks tags) show up. Is there something wrong with my version of VC#.NET?
I can't even get my browser to view XML created webpages. If I click on one of those orange XML boxes that are on some webpages, all I get is the XML coding. Is this suppose to happen? Am I missing something?

I just ran into this problem a few days ago, and found a solution.

The problem occurred after I upgrade my system to Windows XP Service Pack 2. Internet Explorer suddenly started placing the Comment Web Pages in the Restricted zone, and there is no way to tell it to stop doing so. The reason is because each HTM file has <!-- saved from url=(0007)http:// --> as the first line of the document. For whatever reason, Internet Explorer is programmed to treat these files as Restricted documents, and not run any scripts contained within them.

The easiest solution is to do a search and replace on all of these files. From within Visual Studio .NET, Ctrl+Shift+F opens the Find In Files dialog. Choose your CodeCommentReport directory as the "Look In" directory. Have it look for "<!-- saved from url=(0007)http:// -->" and replace with "" (nothing). It will take a few minutes, but when it is complete, you should be able to view your code comment reports without error.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
casmith is offline Offline
1 posts
since May 2005

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C# Forum Timeline: C# Int64, Long, automatic conversion
Next Thread in C# Forum Timeline: Binary data in app.config





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC