Click here to Skip to main content
15,905,148 members
Home / Discussions / C#
   

C#

 
AnswerRe: Splitting up a list of things. Pin
Guffa27-Oct-08 11:19
Guffa27-Oct-08 11:19 
QuestionFormat The XML with Csharp Pin
zjaffary27-Oct-08 10:35
zjaffary27-Oct-08 10:35 
AnswerCross post and Repost Pin
led mike27-Oct-08 11:03
led mike27-Oct-08 11:03 
GeneralRe: Cross post and Repost Pin
Paul Conrad27-Oct-08 12:30
professionalPaul Conrad27-Oct-08 12:30 
QuestionSpeeding up DataGridView RowCount assignment Pin
AndrusM27-Oct-08 10:10
AndrusM27-Oct-08 10:10 
AnswerRe: Speeding up DataGridView RowCount assignment Pin
Wendelius27-Oct-08 10:23
mentorWendelius27-Oct-08 10:23 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
AndrusM27-Oct-08 10:28
AndrusM27-Oct-08 10:28 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
Wendelius27-Oct-08 10:49
mentorWendelius27-Oct-08 10:49 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
AndrusM27-Oct-08 23:53
AndrusM27-Oct-08 23:53 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
Luc Pattyn27-Oct-08 10:33
sitebuilderLuc Pattyn27-Oct-08 10:33 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
AndrusM27-Oct-08 22:58
AndrusM27-Oct-08 22:58 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
Luc Pattyn27-Oct-08 23:28
sitebuilderLuc Pattyn27-Oct-08 23:28 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
AndrusM28-Oct-08 0:09
AndrusM28-Oct-08 0:09 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
Luc Pattyn28-Oct-08 0:31
sitebuilderLuc Pattyn28-Oct-08 0:31 
GeneralRe: Speeding up DataGridView RowCount assignment Pin
AndrusM28-Oct-08 3:30
AndrusM28-Oct-08 3:30 
Questionhow to make call to telephone in c# Pin
ramu20u27-Oct-08 9:21
ramu20u27-Oct-08 9:21 
AnswerRe: how to make call to telephone in c# Pin
MidwestLimey27-Oct-08 9:38
professionalMidwestLimey27-Oct-08 9:38 
AnswerRe: how to make call to telephone in c# Pin
PIEBALDconsult27-Oct-08 18:20
mvePIEBALDconsult27-Oct-08 18:20 
Questionproblem with creating a messagequeue Pin
prasadbuddhika27-Oct-08 9:10
prasadbuddhika27-Oct-08 9:10 
AnswerRe: problem with creating a messagequeue Pin
manfred.bjorlin27-Oct-08 9:14
manfred.bjorlin27-Oct-08 9:14 
QuestionProblems with deserialization of MessageQueue Message Pin
manfred.bjorlin27-Oct-08 9:04
manfred.bjorlin27-Oct-08 9:04 
AnswerRe: Problems with deserialization of MessageQueue Message Pin
Le centriste27-Oct-08 9:33
Le centriste27-Oct-08 9:33 
GeneralRe: Problems with deserialization of MessageQueue Message Pin
manfred.bjorlin28-Oct-08 0:01
manfred.bjorlin28-Oct-08 0:01 
I now have made my own type. The start is like this:
[XmlRoot("StatusSMSMessage", Namespace = "http://www....../specs/schemas/smsgw/StatusSMSMessage.xsd", IsNullable = false)]
public class StatusSMSMessage
{
    public StatusSMSMessage() { }

    [XmlAttribute("mtMessageId")]
    public string mtMessageId;
....


(just removed some of the address inn the Namespace),

And i inizialize my XmlMessageFormatter like this:
using (MessageQueue mq = new MessageQueue(".\\" + qn))
{
    mq.Formatter = new XmlMessageFormatter(new Type[] { typeof(StatusSMSMessage) });
...


But when i try to read the message like

object o = message.Body;


I get the message "Root element missing", but i know the message starts with

<?xml version="1.0" encoding="ISO-8859-1"?>
<StatusSMSMessage xmlns=...

I'm totally new at XML Serialization. Does anyone have a clue to why I get this error message?
GeneralRe: Problems with deserialization of MessageQueue Message Pin
Le centriste28-Oct-08 2:19
Le centriste28-Oct-08 2:19 
GeneralRe: Problems with deserialization of MessageQueue Message Pin
manfred.bjorlin28-Oct-08 2:29
manfred.bjorlin28-Oct-08 2:29 

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.