Valhalla Legends Forums Archive | Visual Basic Programming | DebugOutput for Double-Byte

AuthorMessageTime
Grok
Just yesterday I realized that my DebugOutput function displays double-byte character sets as single-byte output. If someone wants something to do, how about updating it to properly show doublebyte output?
July 8, 2004, 2:21 PM
TheMinistered
Sure, start with posting the code to method debugoutput in this thread.
July 8, 2004, 11:20 PM
Grok
Function DebugOutput
July 8, 2004, 11:32 PM
Adron
I think double-byte output should be optional. When you receive b.net packets, some of the low ascii might be interpreted as double-byte characters, and outputting those as such would ruin the use of it for displaying binary data / single-byte characters.
July 9, 2004, 8:31 AM
Tuberload
[quote author=Adron link=board=31;threadid=7627;start=0#msg69361 date=1089361891]
I think double-byte output should be optional. When you receive b.net packets, some of the low ascii might be interpreted as double-byte characters, and outputting those as such would ruin the use of it for displaying binary data / single-byte characters.
[/quote]

I have very little knowledge of VB, but wouldn't you just convert the string to a byte array and handle it that way?
July 9, 2004, 6:03 PM
Adron
[quote author=Tuberload link=board=31;threadid=7627;start=0#msg69398 date=1089396234]
[quote author=Adron link=board=31;threadid=7627;start=0#msg69361 date=1089361891]
I think double-byte output should be optional. When you receive b.net packets, some of the low ascii might be interpreted as double-byte characters, and outputting those as such would ruin the use of it for displaying binary data / single-byte characters.
[/quote]

I have very little knowledge of VB, but wouldn't you just convert the string to a byte array and handle it that way?
[/quote]

Well, what I mean is that the contents of a packet can be interpreted either as single-byte characters, as is mostly the case with b.net, as multi-byte characters, or as double-byte characters, and this is protocol dependent. The DebugOutput function can't know how to interpret the data you pass it, so there must be a way of telling it.
July 9, 2004, 6:59 PM
TheMinistered
Here is a good way to tell it...
[code]
Public Enum CharacterType
Single = 0
Double = 1
Multiple = 2
End Enum

Public Function DebugOutPut(... , Optional ByVal CharacterType as CharacterType = Single)
[/code]
July 10, 2004, 11:13 PM

Search