ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Appending special characters (https://www.excelbanter.com/excel-programming/345019-appending-special-characters.html)

quartz[_2_]

Appending special characters
 
I am using Office 2003 on Windows XP.

I would like to code certain buttons on a shortcut menu that when clicked
append certain symbols into the active cell always at the end of any text or
values that may already reside in the cell. I can code the shortcut menu bit
without a problem.

The characters I need are prime alpha ('A), beta, delta, and omega. I tried
recording the macro, which works ONLY for beta as: ActiveCell.FormulaR1C1 =
"ß"
The other characters come thru only as question marks.

Can someone please post some concise code illustrating how to do this?
Thanks much in advance.

Toppers

Appending special characters
 
Hi,
One way is to store the special characters in a range of cells
(Insert==Symbol ..) and then append (concatenate) the appropriate character
to the text in your cell(s).

e.g. Cells(1,"C")=Cells(1,"A") & cells(1,"B") where A contains your text
and B contains the required symbol.

HTH

"quartz" wrote:

I am using Office 2003 on Windows XP.

I would like to code certain buttons on a shortcut menu that when clicked
append certain symbols into the active cell always at the end of any text or
values that may already reside in the cell. I can code the shortcut menu bit
without a problem.

The characters I need are prime alpha ('A), beta, delta, and omega. I tried
recording the macro, which works ONLY for beta as: ActiveCell.FormulaR1C1 =
"ß"
The other characters come thru only as question marks.

Can someone please post some concise code illustrating how to do this?
Thanks much in advance.


Gary''s Student

Appending special characters
 
This has nothing to do with buttons. This tiny sub just appends a delta to
whatever single cell you select prior to running the sub:

Sub mmm()
Selection.Value = Selection.Value & ChrW(948)
End Sub

Use other Unicodes for other Greek letters
--
Gary's Student


"quartz" wrote:

I am using Office 2003 on Windows XP.

I would like to code certain buttons on a shortcut menu that when clicked
append certain symbols into the active cell always at the end of any text or
values that may already reside in the cell. I can code the shortcut menu bit
without a problem.

The characters I need are prime alpha ('A), beta, delta, and omega. I tried
recording the macro, which works ONLY for beta as: ActiveCell.FormulaR1C1 =
"ß"
The other characters come thru only as question marks.

Can someone please post some concise code illustrating how to do this?
Thanks much in advance.


Tom Ogilvy

Appending special characters
 
Sub abc()
l = Len(ActiveCell)
ActiveCell.Value = ActiveCell.Value & "ABDO"
ActiveCell.Characters(l + 1, 4).Font.Name = "Symbol"

End Sub


My Greek alphabet may be off, but you should get the idea.

--
Regards,
Tom Ogilvy



"quartz" wrote in message
...
I am using Office 2003 on Windows XP.

I would like to code certain buttons on a shortcut menu that when clicked
append certain symbols into the active cell always at the end of any text

or
values that may already reside in the cell. I can code the shortcut menu

bit
without a problem.

The characters I need are prime alpha ('A), beta, delta, and omega. I

tried
recording the macro, which works ONLY for beta as: ActiveCell.FormulaR1C1

=
"ß"
The other characters come thru only as question marks.

Can someone please post some concise code illustrating how to do this?
Thanks much in advance.




quartz[_2_]

Appending special characters
 
Thanks for all of your suggestions! This covered the issue very well!

"quartz" wrote:

I am using Office 2003 on Windows XP.

I would like to code certain buttons on a shortcut menu that when clicked
append certain symbols into the active cell always at the end of any text or
values that may already reside in the cell. I can code the shortcut menu bit
without a problem.

The characters I need are prime alpha ('A), beta, delta, and omega. I tried
recording the macro, which works ONLY for beta as: ActiveCell.FormulaR1C1 =
"ß"
The other characters come thru only as question marks.

Can someone please post some concise code illustrating how to do this?
Thanks much in advance.



All times are GMT +1. The time now is 07:11 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com