Hi all
I use C# to read messages from msmq queue.
When I knew that it is writing in c# I can read it.
When I knew that it is writing in VB6 I can read it.
How can I know in which format the message is writing?
Moti. 7 1378
Moti,
You should only be writing one type of message to the queue. The way
queues are set up, they are pretty much application specific, and the format
of the messages running through them should be well-defined.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Moti" <Mo**@discussions.microsoft.com> wrote in message
news:4A**********************************@microsof t.com... Hi all
I use C# to read messages from msmq queue. When I knew that it is writing in c# I can read it. When I knew that it is writing in VB6 I can read it. How can I know in which format the message is writing?
Moti.
Hi Nicholas
My queue get messages from VB6 and from C#, there are well-defined, but
if you send a message in vb6, you have to Transleate the msg body string to
UTF8.
Can I have a way to know from which type (vb6 or c#) I receive the message?
I try know the by using the mess.Body string format? (how?)
Is that the way? Is there are a better way?
Moti
"Nicholas Paldino [.NET/C# MVP]" wrote: Moti,
You should only be writing one type of message to the queue. The way queues are set up, they are pretty much application specific, and the format of the messages running through them should be well-defined.
Hope this helps.
-- - Nicholas Paldino [.NET/C# MVP] - mv*@spam.guard.caspershouse.com
"Moti" <Mo**@discussions.microsoft.com> wrote in message news:4A**********************************@microsof t.com... Hi all
I use C# to read messages from msmq queue. When I knew that it is writing in c# I can read it. When I knew that it is writing in VB6 I can read it. How can I know in which format the message is writing?
Moti.
Moti,
If the original application is VB, then you should set the Formatter
property on the MessageQueue class to an instance of the
ActiveXMessageFormatter class. This should translate the messages from VB
correctly.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Moti" <Mo**@discussions.microsoft.com> wrote in message
news:9D**********************************@microsof t.com... Hi Nicholas
My queue get messages from VB6 and from C#, there are well-defined, but if you send a message in vb6, you have to Transleate the msg body string to UTF8. Can I have a way to know from which type (vb6 or c#) I receive the message? I try know the by using the mess.Body string format? (how?) Is that the way? Is there are a better way?
Moti
"Nicholas Paldino [.NET/C# MVP]" wrote:
Moti,
You should only be writing one type of message to the queue. The way queues are set up, they are pretty much application specific, and the format of the messages running through them should be well-defined.
Hope this helps.
-- - Nicholas Paldino [.NET/C# MVP] - mv*@spam.guard.caspershouse.com
"Moti" <Mo**@discussions.microsoft.com> wrote in message news:4A**********************************@microsof t.com... > Hi all > > I use C# to read messages from msmq queue. > When I knew that it is writing in c# I can read it. > When I knew that it is writing in VB6 I can read it. > How can I know in which format the message is writing? > > Moti. >
Hi Nicholas
The application is in c#, but I get messages from c# + vb6 aplication!
If I know which application send it I can read it, but How can i know how
send it?
Moti Saba
"Nicholas Paldino [.NET/C# MVP]" wrote: Moti,
If the original application is VB, then you should set the Formatter property on the MessageQueue class to an instance of the ActiveXMessageFormatter class. This should translate the messages from VB correctly.
-- - Nicholas Paldino [.NET/C# MVP] - mv*@spam.guard.caspershouse.com
"Moti" <Mo**@discussions.microsoft.com> wrote in message news:9D**********************************@microsof t.com... Hi Nicholas
My queue get messages from VB6 and from C#, there are well-defined, but if you send a message in vb6, you have to Transleate the msg body string to UTF8. Can I have a way to know from which type (vb6 or c#) I receive the message? I try know the by using the mess.Body string format? (how?) Is that the way? Is there are a better way?
Moti
"Nicholas Paldino [.NET/C# MVP]" wrote:
Moti,
You should only be writing one type of message to the queue. The way queues are set up, they are pretty much application specific, and the format of the messages running through them should be well-defined.
Hope this helps.
-- - Nicholas Paldino [.NET/C# MVP] - mv*@spam.guard.caspershouse.com
"Moti" <Mo**@discussions.microsoft.com> wrote in message news:4A**********************************@microsof t.com... > Hi all > > I use C# to read messages from msmq queue. > When I knew that it is writing in c# I can read it. > When I knew that it is writing in VB6 I can read it. > How can I know in which format the message is writing? > > Moti. >
You can try reading vb6 format then catch the exception if the message
is not in vb6 format then read it in c# format.
On Tue, 22 Mar 2005 07:41:07 -0800, "Moti"
<Mo**@discussions.microsoft.com> wrote: Hi all
I use C# to read messages from msmq queue. When I knew that it is writing in c# I can read it. When I knew that it is writing in VB6 I can read it. How can I know in which format the message is writing?
Moti.
Hi QWERTY
Sorry on the late answer.
I looking for more elegant way…. But so far I think this is the only way….
Thank you
Moti
"QWERTY" wrote: You can try reading vb6 format then catch the exception if the message is not in vb6 format then read it in c# format.
On Tue, 22 Mar 2005 07:41:07 -0800, "Moti" <Mo**@discussions.microsoft.com> wrote:
Hi all
I use C# to read messages from msmq queue. When I knew that it is writing in c# I can read it. When I knew that it is writing in VB6 I can read it. How can I know in which format the message is writing?
Moti.
Hi QWERTY
Sorry on the late answer.
I looking for more elegant way…. But so far I think this is the only way….
Thank you
Moti
"QWERTY" wrote: You can try reading vb6 format then catch the exception if the message is not in vb6 format then read it in c# format.
On Tue, 22 Mar 2005 07:41:07 -0800, "Moti" <Mo**@discussions.microsoft.com> wrote:
Hi all
I use C# to read messages from msmq queue. When I knew that it is writing in c# I can read it. When I knew that it is writing in VB6 I can read it. How can I know in which format the message is writing?
Moti.
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Lindon |
last post by:
Until now I've been programming straight console apps, and all I've
been doing to compile is a simple 'gcc file1.cpp file2.cpp ....'.
What more is there to know about the compiler? I'd like to know...
|
by: Jeff L. |
last post by:
Maybe I'm missing the obvious solution because I've been looking at
this problem for so long, so I figured I'd throw it out and see if
anyone can come up with some ideas. :)
I'm writing a...
|
by: mike |
last post by:
I am struggling with a problem that should be easy to solve it but has me
stumped. I am writing data to a table using ADO and writing the date to this
table.
I have a calendar control on the...
|
by: Sobhan |
last post by:
Hi all,
Iam writing a small C program to print a array of numbers in
Comma Separated Values in VC++ editor.
Lets say:
Title Title1 Title2
----- ------ ------
10,20,30
50,90,100
120,180,300
|
by: Sam Halliday |
last post by:
i am currently in the process of writing a program to convert a type 1 psf font
file into a file compatible with the linux kernel's format for compiled-in fonts
(see...
|
by: Nadav |
last post by:
Hi,
I am writing some kind of a file scanner, at certain time all of the files
under a certain directory will be scanned, this scan require de-compression
of common files formats such as ZIP and...
|
by: Ven |
last post by:
Hi,
I am reading a kind of below mentioned raw data into my C++ program and
writing it out but I want this to be converted into EBCDIC format, how
can I accomplish this ?
Right now I am using...
|
by: thermate |
last post by:
http://www.latimes.com/news/nationworld/nation/la-na-libby26jan26,1,2730931.story?coll=la-headlines-nation
Aide testifies Cheney helped effort to discredit Wilson
By Richard B. Schmitt, Times...
|
by: mcse jung |
last post by:
Here is asample program that writes a program and then executes it.
Do you knowof a much simpler way of writing a program that writes a program?
"""...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| | |