Click here to Skip to main content
15,899,126 members
Home / Discussions / C#
   

C#

 
QuestionRe: Detect system shutdown Pin
Bob Stanneveld16-Apr-07 1:36
Bob Stanneveld16-Apr-07 1:36 
QuestionSmiley icon to be displayed in listbox. Pin
Nekshan12-Apr-07 23:57
Nekshan12-Apr-07 23:57 
AnswerRe: Smiley icon to be displayed in listbox. Pin
Christian Graus13-Apr-07 0:00
protectorChristian Graus13-Apr-07 0:00 
GeneralRe: Smiley icon to be displayed in listbox. Pin
Luc Pattyn13-Apr-07 1:54
sitebuilderLuc Pattyn13-Apr-07 1:54 
GeneralRe: Smiley icon to be displayed in listbox. Pin
Christian Graus13-Apr-07 10:54
protectorChristian Graus13-Apr-07 10:54 
AnswerRe: Smiley icon to be displayed in listbox. Pin
virendra patel13-Apr-07 0:02
virendra patel13-Apr-07 0:02 
GeneralRe: Smiley icon to be displayed in listbox. Pin
Obaid ur Rehman13-Apr-07 1:39
Obaid ur Rehman13-Apr-07 1:39 
QuestionProblem writing XML Pin
blackjack215012-Apr-07 23:41
blackjack215012-Apr-07 23:41 
Hi. I'm using an XmlTextWriter to write some stuff to an xml file.

I get this exception when I try to write the second node: Token StartElement in state Epilog would result in an invalid XML document.

This code snippet is for illustration purposes:

XmlTextWriter writer = new XmlTextWriter("test.xml", Encoding.UTF8);<br />
<br />
            writer.WriteStartDocument();<br />
            writer.WriteWhitespace(Environment.NewLine);<br />
<br />
            for (int i = 1; i <= 10; i++)<br />
            {<br />
                writer.WriteStartElement("node" + i.ToString());<br />
                writer.WriteValue("CodeProject");<br />
                writer.WriteEndElement();                <br />
            }<br />
            <br />
            writer.Close();


What am I missing or doing wrong?
It should be pretty straightforward, yet...

Thanks.
AnswerRe: Problem writing XML Pin
Christian Graus12-Apr-07 23:46
protectorChristian Graus12-Apr-07 23:46 
GeneralRe: Problem writing XML Pin
blackjack215012-Apr-07 23:50
blackjack215012-Apr-07 23:50 
GeneralRe: Problem writing XML Pin
Christian Graus12-Apr-07 23:50
protectorChristian Graus12-Apr-07 23:50 
GeneralRe: Problem writing XML Pin
Dave Kreskowiak13-Apr-07 3:24
mveDave Kreskowiak13-Apr-07 3:24 
Questionprolog dll Vs c# or C++ ,how and why? Pin
ismail marmoush12-Apr-07 23:38
ismail marmoush12-Apr-07 23:38 
AnswerRe: prolog dll Vs c# or C++ ,how and why? Pin
Christian Graus12-Apr-07 23:50
protectorChristian Graus12-Apr-07 23:50 
GeneralRe: prolog dll Vs c# or C++ ,how and why? Pin
ismail marmoush13-Apr-07 0:01
ismail marmoush13-Apr-07 0:01 
GeneralRe: prolog dll Vs c# or C++ ,how and why? Pin
Christian Graus13-Apr-07 0:15
protectorChristian Graus13-Apr-07 0:15 
GeneralRe: prolog dll Vs c# or C++ ,how and why? Pin
Dan Neely13-Apr-07 2:11
Dan Neely13-Apr-07 2:11 
GeneralRe: prolog dll Vs c# or C++ ,how and why? Pin
ismail marmoush13-Apr-07 5:07
ismail marmoush13-Apr-07 5:07 
AnswerRe: prolog dll Vs c# or C++ ,how and why? Pin
sujithkumarsl13-Apr-07 0:55
sujithkumarsl13-Apr-07 0:55 
GeneralRe: prolog dll Vs c# or C++ ,how and why? Pin
ismail marmoush13-Apr-07 0:58
ismail marmoush13-Apr-07 0:58 
GeneralRe: prolog dll Vs c# or C++ ,how and why? Pin
sujithkumarsl13-Apr-07 1:08
sujithkumarsl13-Apr-07 1:08 
Question[Message Deleted] Pin
sulabh202012-Apr-07 22:41
sulabh202012-Apr-07 22:41 
AnswerRe: How to add bullets to word document using c# Pin
Christian Graus12-Apr-07 23:04
protectorChristian Graus12-Apr-07 23:04 
AnswerRe: How to add bullets to word document using c# Pin
Colin Angus Mackay13-Apr-07 0:18
Colin Angus Mackay13-Apr-07 0:18 
QuestionHow to programmatically add a checkbox column in datatable? Pin
Affan Toor12-Apr-07 22:09
Affan Toor12-Apr-07 22:09 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.