To convert superscripts numbers into glyphs symbols in excel

Hi all,

Im using applescript to copy the data from one input excel file with multiple sheets into final output template, while copy and paste into the output excel template the superscript numbers are converted into normal text.

If I changed all the superscripts into glyphs symbols manually in the input excel file using option in excel Edit → Emojis & Symbols, it appends all superscripts correctly in the output excel file.

Is there anyway to automate via script to convert all the superscripts numbers into glyphs symbols in excel.

Any help is much appreciated!

Hi all,

Im using applescript to copy the data from one input excel file with multiple sheets into final output template, while copy and paste into the output excel template the superscript numbers are converted into normal text.

If I changed all the superscripts into glyphs symbols manually in the input excel file using option in excel Edit → Emojis & Symbols, it appends all superscripts correctly in the output excel file.

Is there anyway to automate via script to convert all the superscripts numbers into glyphs symbols in excel.

Any help is much appreciated!

You already open the second topic, asking the same question not according to the rules of the site. That is, without presenting your efforts (your script fragment). Therefore, the users do not answer you.

I also will not provide a ready-made script, but for another reason - I have Excel uninstalled. I’ll just show you an idea of what you will have to deal with, but if you start your script yourself with Excel, then most likely other users (those who have this application) will help you:

-- numbers list (it is my choice only, you can indicate other numbers)
set numbersList to {1, 15, 235, 460, 1001} 
-- corresponding emboli symbols list (it is my choice only, you can indicate other symbols) 
set symbolsList to {character id 128189, character id 128225, character id 128424, character id 128161, character id 128295}
-- matchList (trick to get fastly the index of the selected number in the list)
set matchList to {"-1-", "-2-", "-3-", "-4-", "-5-"}

set numberValue to 15 -- that is, I select here the second item of numbersList
set aPosition to my indexOf(numberValue, numbersList)
set symbolValue to item aPosition of symbolsList

on indexOf(theItem, theList)
	set oTIDs to AppleScript's text item delimiters
	set AppleScript's text item delimiters to return
	set theList to return & theList & return
	set AppleScript's text item delimiters to oTIDs
	try
		-1 + (count (paragraphs of (text 1 thru (offset of (return & theItem & return) in theList) of theList)))
	on error
		0
	end try
end indexOf