0

On a PC I have these chars with their ASCii code 178,188,189 respectively. But when I use the CODE function on MAC VBA Excel I always get 95 for all three different chars.

char PC MAC ² 178 95 ½ 188 95 ¾ 189 95 

How can I distinguish between these 3 chars on the MAC? or phrased differently, is there a function on the MAC VBA Excel that gives me different values for these 3 chars, even if they are "MAC Ascii" values, as long as they are different

12
  • How do these characters "arrive" on the Mac? Do they come from a PC generated workbook? Do they show up correctly in the cells? Commented May 18, 2013 at 23:29
  • I get them in a txt file and copy that into excel on the mac or on the pc Commented May 18, 2013 at 23:31
  • Could be a file encoding issue, ansi vs utf8 etc Commented May 18, 2013 at 23:34
  • How is the txt file encoded? Commented May 18, 2013 at 23:34
  • How do I find that out? Commented May 18, 2013 at 23:35

1 Answer 1

0

The table you gave for the ASCII codes is wrong.

The correct table is:

char PC MAC ² 178 253 ½ 189 171 ¾ 190 243 

Hope it helps

Sign up to request clarification or add additional context in comments.

4 Comments

Hello, yes for PC you are right, I just mixed up one line - to get these numbers I used the CODE function on PC. BUT ON MAC I ALWAYS GET 95 WHEN I USE THE CODE FUNCTION. HOW DID YOU GET THESE NUMBERS ON THE MAC? ps the three chars are in three cells in an Excel spreadsheet and the CODE function is either in a formula or in VBA code, makes no difference
i got the numbers here
OK, thanks. Unfortunately the function on the MAC does not work correctly and does not return the correct value. Thank's for your help!
How do you get these values from a function? On other words, what code will tell you what character is in the cell if it was imported from a PC (or what is the ASCII code of the value in the cell)? That seems to be the real question... I don't understand why this is marked as "answered"!

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.