Click to See Complete Forum and Search --> : String Problem With Chinese Converter Activated


Gary Ng
July 23rd, 1999, 09:39 PM
Hi, I am currently using VB 5.0 to write a program. I face a problem when I try to obtain a string from the below codes:

Dim str1 as String
Dim str2 as String
Dim str3 as String
Dim str4 as String
Dim str5 as String
Dim str6 as String
Dim str7 as String

str1= Chr$(&HBD)
str2= Chr$(&HDE)
str3= Chr$(&H6F)
str4= Chr$(&H37)
str5= Chr$(&H83)
str6= Chr$(&H83)
str7= str1 & str2 & str3 & str4 & str5 & str6

When I run and debug, I got the result as below, which is the correct answer!
str1=½
str2=Þ
str3=o
str4=7
str5=ƒ
str6=ƒ
str7= ½Þo7ƒƒ

However, the problem comes when I run this code, with my “Rich Win” (my Chinese Converter) activated at the background (and, I believe the same case will happen if I run other type of Converter such as Japanese Converter…etc.), I got a wrong result. Here is what I got:
str1=½
str2=Þ
str3=o
str4=7
str5=?
str6=?
str7=?To7??

I believe that the converter changes my Ascii Code into Ansi Code.

Please can somebody help me to solve this problem as soon as possible, where I can run my “Rich Win” at the background as well.

Thank a lot!

Gary
24/7