Results 1 to 11 of 11

Thread: Urgent Help Unicode Support

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Dec 2009
    Posts
    99

    Question Urgent Help Unicode Support

    i make an app which can lock the file but it has also a default password and this default password is in unicode for example "اس ا و ت و" and it is written in app
    it working correctly if target system has installed URDU Language on it but not worked with others . Password is inside the app why it is not working with other systems if there is any way to do so ?

  2. #2
    King of sapila
    Join Date
    Oct 2006
    Location
    Greece
    Posts
    6,763

    Re: Urgent Help Unicode Support

    Try using globalization and localization , if this does not work,
    try distributing the language pack within the installation file(s).
    ἄνδρα μοι ἔννεπε, μοῦσα, πολύτροπον, ὃς μάλα πολλὰ
    πλάγχθη, ἐπεὶ Τροίης ἱερὸν πτολίεθρον ἔπερσεν·

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Dec 2009
    Posts
    99

    Re: Urgent Help Unicode Support

    its hard to distribute the language pack any other way ?

  4. #4
    Frenzied Member
    Join Date
    Mar 2005
    Location
    Sector 001
    Posts
    1,577

    Re: Urgent Help Unicode Support

    What is the user entering if he can't enter "اس ا و ت و" ?
    VB 2005, Win Xp Pro sp2

  5. #5
    King of sapila
    Join Date
    Oct 2006
    Location
    Greece
    Posts
    6,763

    Re: Urgent Help Unicode Support

    Quote Originally Posted by hackerspk View Post
    its hard to distribute the language pack any other way ?
    eh???
    ἄνδρα μοι ἔννεπε, μοῦσα, πολύτροπον, ὃς μάλα πολλὰ
    πλάγχθη, ἐπεὶ Τροίης ἱερὸν πτολίεθρον ἔπερσεν·

  6. #6

    Thread Starter
    Lively Member
    Join Date
    Dec 2009
    Posts
    99

    Re: Urgent Help Unicode Support

    Quote Originally Posted by Half View Post
    What is the user entering if he can't enter "اس ا و ت و" ?
    he is entering this string but not accepted by app , in reply app give msgbox "wrong password"

  7. #7
    Frenzied Member
    Join Date
    Mar 2005
    Location
    Sector 001
    Posts
    1,577

    Re: Urgent Help Unicode Support

    How can he enter the string if he does not have the language installed? What I mean is you can't
    enter 'фгресфхз' with your keyboard for example when you don't have cyrillic support installed.

    So is your client trying a copy & paste or how is he doing it?

    First you need to identify the codes for the unicode symbols using the windows charmap (run -> charmap) or with code. Then enter these codes through the numpad of your keyboard using one of the suggsted ways here.

    What I am saying is that you can first try entering the password on your computer using unicode hex code and if that works tell the client to do the same.
    VB 2005, Win Xp Pro sp2

  8. #8
    You don't want to know.
    Join Date
    Aug 2010
    Posts
    4,578

    Re: Urgent Help Unicode Support

    How are you saving/loading the password? If you stored it in ASCII it's going to be impossible to make it work without asking the user to install that language pack. If you used a Unicode encoding, it's difficult but possible to enter characters using charmap like Half mentioned. But it's *only* going to work if everything is in Unicode.

  9. #9
    Frenzied Member
    Join Date
    Mar 2005
    Location
    Sector 001
    Posts
    1,577

    Re: Urgent Help Unicode Support

    If it really is about ASCII and not unicode, the task gets easier, not impossible.

    Let's say we have the string س ا و ت و on a computer whose codepage (extended ascii) is Urdu. Let's say the user's codepage is Russian.

    If the ascii code for the char س is 171 in the Urdu codepage then the user has to enter the Russian char whose code is also 171 which is «

    Then comes ا, if its code is 139, the user enters what 139 in Russian is: ‹

    For و if it is 221, the same in Russian will be Э

    Then comes ت. If its code is 205, Russian equivalent is Н.

    And again Э for و

    So a Russian user enters « ‹ Э Н Э and the resulting codes are the same.

    Now I don't know the actual codes of the Urdu string but they can be found through the Asc (TheChar) function in vb.
    VB 2005, Win Xp Pro sp2

  10. #10

    Thread Starter
    Lively Member
    Join Date
    Dec 2009
    Posts
    99

    Re: Urgent Help Unicode Support

    Code:
       Dim pass As String
            Dim textfile As New StreamReader("PAf")
            pass = textfile.ReadLine()
            If pass = txtPass.text Then
                textinfo.text = textfile.ReadToEnd
     Else
                MsgBox("Password Incorrect")
            End If
    user have a text file and he want to read it but admin ser a unicode password he enter the password but he got the msgbox "Password Incorrect" he also use copy & paste method but all in vain but if the password is normal like "mypass" then its working fine

  11. #11

    Thread Starter
    Lively Member
    Join Date
    Dec 2009
    Posts
    99

    Re: Urgent Help Unicode Support

    Quote Originally Posted by Half View Post
    If it really is about ASCII and not unicode, the task gets easier, not impossible.

    Let's say we have the string س ا و ت و on a computer whose codepage (extended ascii) is Urdu. Let's say the user's codepage is Russian.

    If the ascii code for the char س is 171 in the Urdu codepage then the user has to enter the Russian char whose code is also 171 which is «

    Then comes ا, if its code is 139, the user enters what 139 in Russian is: ‹

    For و if it is 221, the same in Russian will be Э

    Then comes ت. If its code is 205, Russian equivalent is Н.

    And again Э for و

    So a Russian user enters « ‹ Э Н Э and the resulting codes are the same.

    Now I don't know the actual codes of the Urdu string but they can be found through the Asc (TheChar) function in vb.

    ok i will check this one i have ASC Chra for urdu

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width