Encoding character issue??? Help!

Homepage Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Encoding character issue??? Help!

  • Creator
    Topic
  • #54379
    Mike Wilson
    Participant

    I am having issue sending messages intermittently.  Apparently the vendor is sending over what appears to be an apostrophe but is not.  The Testing tool finds the character and replaces it but it wont work in the LIVE data stream.  The character in question is ”

Viewing 9 reply threads
  • Author
    Replies
    • #81235
      David Barr
      Participant

      If the vendor won’t fix it you could try fixing it in TCL:

      Code:

      set msg [msgget $mh]
      regsub -all “u2019” $msg “‘” msg
      msgset $mh $msg

    • #81236
      Mike Wilson
      Participant

      Whats the “u2019” ?

      Is that the code for that specific character?

    • #81237
      David Barr
      Participant

      Yes, I looked it up here:

      http://unicodelookup.com/#0x2019/1

    • #81238
      Mike Wilson
      Participant

      unfortunately that didn’t work either.  The sections in bold are where the issue is.

      Here is what the actual text from the EMR looks like:

      Comparison is made to the patient

    • #81239
      David Barr
      Participant

      From the debug window it looks like your bad character has a hex value of hex 92, so you could use the same regsub but replace the u2019 with x92.

    • #81240
      Mike Wilson
      Participant

      David Barr wrote:

      From the debug window it looks like your bad character has a hex value of hex 92, so you could use the same regsub but replace the u2019 with x92.

      David, I have tried that as well.  It simply wont recognize that character with my TCLproc.  Im stumped.

    • #81241
      David Barr
      Participant

      What do you have the encoding set to on the inbound thread? It looks like your sender is using “windows-1252”.

    • #81242
      Mike Wilson
      Participant

      the Vendor is Meditech C/S 5.66.  I have the encoding set to bypass right now.  I have been changing it to see if I can get any change with no luck.

    • #81243
      David Barr
      Participant

      I’d try setting the inbound encoding to windows-1252, then using the regsub with u2019. Setting the encoding to 1252 should allow Cloverleaf to properly convert the characters to Unicode, then you can use the Unicode character code to replace with the plain ASCII equivalent.

    • #81244
      Mike Wilson
      Participant

      David Barr wrote:

      I’d try setting the inbound encoding to windows-1252, then using the regsub with u2019. Setting the encoding to 1252 should allow Cloverleaf to properly convert the characters to Unicode, then you can use the Unicode character code to replace with the plain ASCII equivalent.

      That did the trick!  What a pain.  Thank you David!

Viewing 9 reply threads
  • The forum ‘Cloverleaf’ is closed to new topics and replies.

Forum Statistics

Registered Users
5,053
Forums
28
Topics
9,236
Replies
34,175
Topic Tags
273