消息队列异常 [英] Message Queue Exception

查看:111
本文介绍了消息队列异常的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨..



当我尝试使用微软消息队列控制时出现此错误。



这样的错误

Hi..

I got this error when I m trying to use microsoft message queue control.

The error like this

"The queue does not exist or you do not have sufficient permissions to perform the operation."





代码如下。



And the code is as follows.

private void btnsend_Click(object sender, EventArgs e)
{
      Payment payment;
      payment.Payor = textBox1.Text;
      payment.Payee = textBox2.Text;
      payment.Amount =Convert.ToInt32 ( textBox3.Text);
      payment.DueDate = textBox4.Text;
      System.Messaging.Message msg = new System.Messaging.Message();
      msg.Body = payment;
      MessageQueue myque = new MessageQueue(".\\private$\\billpay");
      myque.Send(msg);
}





请给我解决方案。

提前致谢。



Please give me solution.
Thanks in advance.

推荐答案

\\billpay);
myque.Send(msg);
}
\\billpay"); myque.Send(msg); }





请给我解决方案。

提前致谢。



Please give me solution.
Thanks in advance.


线索在错误信息中.. 。

检查队列是否确实存在 http://technet.microsoft.com /en-gb/library/bb684791.aspx [ ^ ]

队列的名称( .\\private
The clue is in the error message...
Check that the queue actually exists http://technet.microsoft.com/en-gb/library/bb684791.aspx[^]
The name of the queue (.\\private


\\ 会建议它不是公共队列(!)所以它必须正确配置才能发送消息。注意默认权限随MSMQ 4.0而改变



这里是完整文档的链接http://technet.microsoft.com/en-us/library/jj667988.aspx [ ^ ]


这篇关于消息队列异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆