返回首页

您好,
我刚刚试图使用MSMQ在asp.net.When的,我试着点击发送按钮,显示以下错误..

public System.Messaging.MessageQueue mq;

    public static Int32 i = 0;

 

protected void Button1_Click(object sender, EventArgs e)

  {

      System.Messaging.Message mm = new System.Messaging.Message();

      mm.Body = TextBox1.Text;

      mm.Label = "MsgI" + i.ToString();

      i++;

      mq.Send(mm);//Error msg:Object reference not set to an instance of an object.

}
请告诉我这是什么错误......

谢谢。

回答

评论会员:R 时间:2