Results 1 to 5 of 5
  1. #1
    Join Date
    Feb 2007
    Posts
    348

    Unanswered: ADD a special character

    Hello all,
    I've used VBA in Access but not much in Excel so please forgive my ignorance. I have a user that has a reason to use the greek letter Psi repeatedly in her excel spreadsheets. To get this letter I can type 03c8 then hit Alt+X. I can get it to show up in an excel cell this way. I would like to give her a toolbar button, per her request, she doesn't have to type all that and so I can give her a shortcut key. How in Excel can I insert this special character at the location of the cursor?

  2. #2
    Join Date
    Oct 2003
    Posts
    1,091
    Howdy. Can you record the macro and the steps you are using? Does anything show up?
    old, slow, and confused
    but at least I'm inconsistent!

    Rich
    (retired Excel 2003 user, 3/28/2008)

    How to ask a question on forums

  3. #3
    Join Date
    Feb 2007
    Posts
    348
    Sorry I haven't responded sooner. I wanted to get a chance to work on it some more.
    So I can not get the character to show up in Excel. I can create it in word and paste it into excel and it stays. Then if I run the code function on it I get the number 63 returned to me. If I run the char function on 63 I get a question mark back. If I run both Char(Code(PsiCellHere)) then I get the question mark there as well.
    So unless I write some kind of macro that grabs the psi from somewhere else and uses the clipboard, I'm not sure how to do it. I will contact my user to see if it is just one workbook or several that she is using this in.

    Another option that I could pursue but would need a little direction on: I'm told that the capital Y in Symbols also results in a Psi. So if I wrote something to grab the current font, change to Symbols, type Y, then return the font, that may do it too.

    Any thoughts or suggestions?

  4. #4
    Join Date
    Oct 2003
    Posts
    1,091
    On my Win XP, with Symbol, the PSI character is 89.

    This code will insert the value:

    Code:
    Sub LetterPSI()
        ActiveCell.FormulaR1C1 = "Y"
        ActiveCell.Font.Name = "Symbol"
    End Sub
    Put it in the Personal Macro Workbook. Save it.

    Then right-click the toolbars and choose Customize. In the middle tab, on the left choose Macro, on the right, click on "Custom menu item" and hold down as you drag to a toolbar (when you see the dark vertical line, release the mouse).

    Then right click it and choose "Assign macro" and select this one. Right-click again and change name to something like PSI. Click OK.
    old, slow, and confused
    but at least I'm inconsistent!

    Rich
    (retired Excel 2003 user, 3/28/2008)

    How to ask a question on forums

  5. #5
    Join Date
    Feb 2007
    Posts
    348
    That works like a dream. Thanks very much.

Posting Permissions

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