Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Trouble Getting UFT to Work with Simplified Chinese
#1
Not Solved
Hi all. I'm hoping somebody out there can be of some help to me.

I'm trying to enhance my existing scripts, which were written and work in English, to work with Simplified Chinese. The scripts are used to create a basic case and the only pieces that need to be translated is the drop down values. The lists do not have all of the same values and sort order for each language. So, for example, the English list could have  A, B, C, and D and the Chinese list could have B, C, F, and G. We have been able to successfully adapt and run  these scripts in Spanish, French, German, and Italian.

The method we have used for the other languages is to store all of the values in a local CSV file and do a lookup in the file of the English word when a translation is needed. Below is the code on how we declare in the CSV file and a snip of a row in the CSV file.

My problem is when the Chinese values are read into UFT (v12.02) from the CSV file, they do not match; therefore, no value is selected. In the CSV file snippet, you can see the characters for China are displayed as "中国" but  "涓浗" is what I see in UFT.


Anybody have any thoughts?
Thanks,

Harry


Code:
' Define connection and recordset and read table
    Set objConnection = CreateObject("ADODB.Connection")
    Set objRecordSet = CreateObject("ADODB.Recordset")

    strPathtoTextFile = "D:\UPSData\QTP\Input Data\"
    strFileName = "ECM_LOV_TranslationDecode.csv"
    
    objConnection.Open "Provider=Microsoft.Jet.OLEDB.4.0;" & _  
    "Data Source=" & strPathtoTextFile & ";" & _
    "Extended Properties=""text;HDR=YES;FMT=Delimited"""

Code:
COUNTRY,Country,CN,China,China,Cina,Chine,China,中国,
Reply
#2
Not Solved
This is an encoding issue, you have to convert the non-ascii to unicode and then use the same in your script.
Thanks,
SUpputuri
Reply
#3
Not Solved
Did u install language pack of the UFT 12.02
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  File Chooser on Chrome doesn't work - UFT 15.0.1 Nenna Rosa 1 3,658 10-31-2020, 01:16 PM
Last Post: Ankur
  Having trouble integrating QTP with Ant and a multi-module Adobe Flex application peachy32514 0 4,802 03-24-2012, 02:39 AM
Last Post: peachy32514
  WinTreeView - Trouble in extracting the content of the Node Gurushankar 0 3,640 11-21-2011, 07:15 PM
Last Post: Gurushankar
  QTP Version 10 trouble on Citrix adityasrinivasb 0 3,015 06-19-2011, 07:54 PM
Last Post: adityasrinivasb
  Trouble with For loop Mala 2 3,209 06-16-2011, 07:06 PM
Last Post: Mala

Forum Jump:


Users browsing this thread: 2 Guest(s)