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 » IBM MQ API Support » Problem in putting mesages in the Remote Q with VB Code

Post new topic  Reply to topic
 Problem in putting mesages in the Remote Q with VB Code « View previous topic :: View next topic » 
Author Message
rajagopalan
PostPosted: Fri May 26, 2006 3:47 am    Post subject: Problem in putting mesages in the Remote Q with VB Code Reply with quote

Newbie

Joined: 14 May 2006
Posts: 1

Dear Gurus,

Iam facing a strange type of error in my Application while accessing my Queue Manager, i.e when my application try to put the messages in the remote queue definiton of my Queue Manager it throws the following error.

MQAX200.MQQueueManager::AccessQueue CompletionCode = 2, ReasonCode = 2045, ReasonName = MQRC_OPTION_NOT_VALID_FOR_TYPE

However i am able to put the message in the local queue of the Queue Manager.

Iam using VB application.

Mqseries 5.3 for windows CSD1 has been installed in my MQserver and the MQclient where my VB application is running is being installed with MQseries Client 5.3.

Please find enclosed the piece of code what iam using in the application code.

Public Sub PutMQString(ByVal str As String)
Dim MQPutMessageOptions As MQAX200.MQPutMessageOptions
Dim MQMessage As MQAX200.MQMessage

On Error GoTo ErrorPlace
Err.Clear

Set MQPutMessageOptions = gMQSession.AccessPutMessageOptions()
With MQPutMessageOptions
.Options = MQPMO_NO_SYNCPOINT
End With

Set MQMessage = gMQSession.AccessMessage()
gMQSession.ExceptionThreshold = 3

With MQMessage
.CharacterSet = MQCCSI_Q_MGR
.Format = "MQSTR"
.WriteInt2 Len(str)
.WriteString str
End With
Debug.Print str
gMQQueue.Put MQMessage, MQPutMessageOptions
Select Case gMQSession.ReasonCode
Case MQRC_NONE

Case Else
Call ShowMessage(gMQSession.ReasonName)
End Select
Set MQPutMessageOptions = Nothing
Exit Sub.


Suggest me to solve this issue

Venkat
Back to top
View user's profile Send private message
kevinf2349
PostPosted: Fri May 26, 2006 5:19 am    Post subject: Reply with quote

Grand Master

Joined: 28 Feb 2003
Posts: 1311
Location: USA

Just a couple of things....

First MQ 5.3 CSD01 is pretty old and I know there was issues with .Net in CSD's prior to CSD7. Personally I would put CSD12 on as soon as possible.

Next is that we would need to see the Object descriptor used for the Open as the usual cause for a 2045 is a screw up with the open options.
Back to top
View user's profile Send private message
wschutz
PostPosted: Fri May 26, 2006 5:52 am    Post subject: Reply with quote

Jedi Knight

Joined: 02 Jun 2005
Posts: 3316
Location: IBM (retired)

I'd bet he's opening the queue for INPUT was well as output which works for local queues but fails for qremotes....
_________________
-wayne
Back to top
View user's profile Send private message Send e-mail AIM Address
tleichen
PostPosted: Fri May 26, 2006 12:24 pm    Post subject: Re: Problem in putting mesages in the Remote Q with VB Code Reply with quote

Yatiri

Joined: 11 Apr 2005
Posts: 663
Location: Center of the USA

rajagopalan wrote:

Iam facing a strange type of error in my Application while accessing my Queue Manager, i.e when my application try to put the messages in the remote queue definiton of my Queue Manager it throws the following error.

MQAX200.MQQueueManager::AccessQueue CompletionCode = 2, ReasonCode = 2045, ReasonName = MQRC_OPTION_NOT_VALID_FOR_TYPE

However i am able to put the message in the local queue of the Queue Manager.



I don't think MQPMO_NO_SYNCPOINT is valid for a remote queue.
_________________
IBM Certified MQSeries Specialist
IBM Certified MQSeries Developer
Back to top
View user's profile Send private message
PeterPotkay
PostPosted: Fri May 26, 2006 12:28 pm    Post subject: Reply with quote

Poobah

Joined: 15 May 2001
Posts: 7722

Sure it is.
_________________
Peter Potkay
Keep Calm and MQ On
Back to top
View user's profile Send private message
mvic
PostPosted: Fri May 26, 2006 12:38 pm    Post subject: Re: Problem in putting mesages in the Remote Q with VB Code Reply with quote

Jedi

Joined: 09 Mar 2004
Posts: 2080

rajagopalan wrote:
MQAX200.MQQueueManager::AccessQueue CompletionCode = 2, ReasonCode = 2045

Please post the code that calls MQAX200.MQQueueManager::AccessQueue(). As wschutz says, it is highly likely that an MQOO_INPUT_* option is being specified.
Back to top
View user's profile Send private message
tleichen
PostPosted: Fri May 26, 2006 12:54 pm    Post subject: Reply with quote

Yatiri

Joined: 11 Apr 2005
Posts: 663
Location: Center of the USA

PeterPotkay wrote:
Sure it is.



Oh, that's right it's some of the open options that are not valid for remote queues, like :

MQOO_INPUT_AS_Q_DEF
MQOO_INPUT_SHARED
MQOO_INPUT_EXCLUSIVE
MQOO_BROWSE
MQOO_INQUIRE
MQOO_SET
_________________
IBM Certified MQSeries Specialist
IBM Certified MQSeries Developer
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 » IBM MQ API Support » Problem in putting mesages in the Remote Q with VB Code
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.