利用
public static void SendComStr(string strPath,string data,string strTitle)
{
MessageQueue q = new System.Messaging.MessageQueue(strPath);
q.Formatter=new ActiveXMessageFormatter();
q.Send(data,strTitle);
}
在windows 2003 server中调用此方法发送MQ消息,程序能正常运行,但隔一段时间后,再次运行就会出现“此计算机上尚未安装“消息队列”。的异常,需要切换到另一个应用程序池方可继续运行,如此往复,不知道是何原因,求高手解答,消息队列已重装了n次。。靠
public static void SendComStr(string strPath,string data,string strTitle)
{
MessageQueue q = new System.Messaging.MessageQueue(strPath);
q.Formatter=new ActiveXMessageFormatter();
q.Send(data,strTitle);
}
在windows 2003 server中调用此方法发送MQ消息,程序能正常运行,但隔一段时间后,再次运行就会出现“此计算机上尚未安装“消息队列”。的异常,需要切换到另一个应用程序池方可继续运行,如此往复,不知道是何原因,求高手解答,消息队列已重装了n次。。靠
{
// Connect to a queue on the local computer.
MessageQueue myQueue = new MessageQueue(".\\myQueue"); // Send a message to the queue.
myQueue.Send("My message data1.");
// Explicitly release resources.
myQueue.Close(); return;
}