General discussion


Problem reading MSMQ

By colwa02 ·
What would the code look like to read this queue, one at a time and not remove the message when the read completes?

Here is a partial listing of the C# windows console application code snipets of the message put code:
MessageQueue que = new MessageQueue(".\\private$\\inbound");
que.Formatter = new BinaryMessageFormatter();
myMessage msg = new myMessage();
/* load the msg object here, many lines */
Object obj = msg;
Message mput = new Message();
mput.Label = "myAutomation";
mput.Priority = MessagePriority.High;
mput.UseDeadLetterQueue = true;
mput.Body = obj;
mput.Formatter = new BinaryMessageFormatter();

Every time i attempt a read, i can't see the actual data.

This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Comments

Related Discussions

Related Forums