Click here to Skip to main content
15,900,378 members
Home / Discussions / C#
   

C#

 
AnswerRe: Serilization Types Pin
Tauseef A24-Mar-07 3:22
Tauseef A24-Mar-07 3:22 
AnswerRe: Serilization Types Pin
malharone25-Mar-07 6:58
malharone25-Mar-07 6:58 
QuestionMSDN like help Pin
Tauseef A23-Mar-07 22:28
Tauseef A23-Mar-07 22:28 
AnswerRe: MSDN like help Pin
Stefan Troschuetz23-Mar-07 22:37
Stefan Troschuetz23-Mar-07 22:37 
QuestionIntellisence Pin
Kanjinghat23-Mar-07 20:44
Kanjinghat23-Mar-07 20:44 
AnswerRe: Intellisence Pin
Stefan Troschuetz23-Mar-07 22:42
Stefan Troschuetz23-Mar-07 22:42 
AnswerRe: Intellisence Pin
Mike Hankey23-Mar-07 23:18
mveMike Hankey23-Mar-07 23:18 
QuestionSystem.Xml Pin
thecodedemon23-Mar-07 19:43
thecodedemon23-Mar-07 19:43 
Using C# and .NET, I need to make an XML document. I've searched and all i can find is info on using XmlReader and XmlWriter, or XmlDocument after loading an already existing XML file. Problem is, I don't have or need a file. I really can't even make the file, due to security issues. I need to be able to make the XML structure in memory. Below is a sample of what I've tried so far, and the error it gives me.


XmlDocument doc = new XmlDocument();<br />
XmlNode node;<br />
<br />
// make a node<br />
node = doc.CreateTextNode( "This is a text node." );<br />
// add it to the doc<br />
doc.AppendChild( node );  <-- System.InvalidOperationException was unhandled, "The specified node cannot be inserted as the valid child of this node, because the specified node is the wrong type."


I know I have all the right "using's", it compiles fine. My guess is the XmlDocument isn't initialized correctly, but i can't find info on how else to do so.

Any help would be greatly appreciated.


A soft glow comes from the pit in the darkness.
The clicking noise become faster - and louder.
A wind begins to stir up from the pit, as the
creature flexes it's wings, preparing for flight.
You stare into the pit, and hear a voice say
in your mind, "If you survive the encounter,
declare it to the world."

The Code Demon Rises.
AnswerRe: System.Xml Pin
Stefan Troschuetz23-Mar-07 22:50
Stefan Troschuetz23-Mar-07 22:50 
GeneralRe: System.Xml Pin
thecodedemon24-Mar-07 4:24
thecodedemon24-Mar-07 4:24 
GeneralRe: System.Xml Pin
Stefan Troschuetz24-Mar-07 4:44
Stefan Troschuetz24-Mar-07 4:44 
GeneralRe: System.Xml Pin
thecodedemon24-Mar-07 4:53
thecodedemon24-Mar-07 4:53 
GeneralRe: System.Xml Pin
Stefan Troschuetz24-Mar-07 5:11
Stefan Troschuetz24-Mar-07 5:11 
Questiontimer_tick Pin
yaminilatha23-Mar-07 18:27
yaminilatha23-Mar-07 18:27 
AnswerRe: timer_tick Pin
Christian Graus23-Mar-07 18:36
protectorChristian Graus23-Mar-07 18:36 
GeneralRe: timer_tick Pin
yaminilatha29-Mar-07 2:12
yaminilatha29-Mar-07 2:12 
QuestionBuilding Audio Apps Using C# Pin
mikepalma23-Mar-07 18:13
mikepalma23-Mar-07 18:13 
AnswerRe: Building Audio Apps Using C# Pin
Christian Graus23-Mar-07 18:35
protectorChristian Graus23-Mar-07 18:35 
QuestionNo overload for method take "0" arguments Pin
chitra4sat23-Mar-07 18:08
chitra4sat23-Mar-07 18:08 
AnswerRe: No overload for method take "0" arguments Pin
Christian Graus23-Mar-07 18:31
protectorChristian Graus23-Mar-07 18:31 
GeneralRe: No overload for method take "0" arguments Pin
chitra4sat23-Mar-07 19:21
chitra4sat23-Mar-07 19:21 
GeneralRe: No overload for method take "0" arguments Pin
abhinarulkar23-Mar-07 20:13
abhinarulkar23-Mar-07 20:13 
GeneralRe: No overload for method take "0" arguments Pin
chitra4sat23-Mar-07 20:31
chitra4sat23-Mar-07 20:31 
GeneralRe: No overload for method take "0" arguments Pin
Stefan Troschuetz23-Mar-07 23:37
Stefan Troschuetz23-Mar-07 23:37 
Questionbranching and skip logic Pin
econner23-Mar-07 16:37
econner23-Mar-07 16:37 

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.