ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » General Discussion » BROWSE MESSAGE NOT WORKING

Post new topic  Reply to topic
 BROWSE MESSAGE NOT WORKING « View previous topic :: View next topic » 
Author Message
dcsnfh
PostPosted: Tue Oct 14, 2003 2:26 pm    Post subject: BROWSE MESSAGE NOT WORKING Reply with quote

Newbie

Joined: 14 Oct 2003
Posts: 3

Hi, after 3 days working in this i give up.

Can anyone tell wath is wrong with this code?

Set Queue = QMgr.AccessQueue(CanalM.NombreCola, 1 Or 8192 Or 32)
Set Msg = CreateObject("mqax200.MQMessage")
Set Gmo = MQSess.AccessGetMessageOptions()
Gmo.Options = 16

Queue.Get Msg, Gmo
Hay = True
While Hay
If Queue.ReasonName = "MQRC_NO_MSG_AVAILABLE" Then
If i = 0 Then
Hay = False
End If
Else
Hay = True
msgbox Msg.messageidhex
End If
Gmo.Options = 32
Queue.Get Msg, Gmo<- here explodes
End If
Wend
when i use Options = 32 after using Options = 16 it says MQRC_NO_MSG_AVAILABLE even with more messages in queue.

if i use Options = 32 it don't get the next message, always stays at the same position.

Can any one help me please?

Dario
Back to top
View user's profile Send private message
bob_buxton
PostPosted: Tue Oct 14, 2003 11:58 pm    Post subject: Reply with quote

Master

Joined: 23 Aug 2001
Posts: 266
Location: England

You need to set message id and correlid to null between each get.
By not resetting them you are looking for a second message with the same ids as the previous.
_________________
Bob Buxton
Ex-Websphere MQ Development
Back to top
View user's profile Send private message
dcsnfh
PostPosted: Wed Oct 15, 2003 4:34 am    Post subject: Reply with quote

Newbie

Joined: 14 Oct 2003
Posts: 3

How can i set this to null in VB?

Thanks,
Back to top
View user's profile Send private message
dcsnfh
PostPosted: Wed Oct 15, 2003 4:43 am    Post subject: ClearMessage Reply with quote

Newbie

Joined: 14 Oct 2003
Posts: 3

Problem solved!!!!!

I must use ClearMessage before gettind next message.

Thanks a lot!.

Dario :D
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General Discussion » BROWSE MESSAGE NOT WORKING
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.