how to escape "+" or " -"

C

clara

Hi all,
when I input "+" or" -", there is alway a marqueue, how can I prevent the
marqueue?

Clara
thank you so much for your help
 
S

Susan

i didn't understand WHAT the heck you were talking about, so i tried
it - now i understand.
when you put + or -, excel thinks it's part of a formula & is looking
for the next value of the formula, hence the marqueue (or, as some
people call it, the marching ants).
if you want JUST that character in a cell, use an apostrophe before it
& that will tell excel it is a text cell, not part of a formula
'+
or
'-

hope this helps!
susan
 
C

clara

Hi Susan,

Thank you very much! Here is another question.
When I use code to assign "'+" or "'-" to a range, the apostrophe is also
displayed which is not wanted. How can I do it?

Clara

thank you so much for your help
 
S

Susan

i didn't know, so i turned on the macro recorder & recorded inputting
'+ & '-........
this is what i got

Sub Macro1()
'
' Macro1 Macro
' Macro recorded 3/22/2007 by Susan
'
ActiveCell.FormulaR1C1 = "'+"
Range("D4").Select
ActiveCell.FormulaR1C1 = "'-"
Range("E4").Select
End Sub

and the apostrophe disappears when it's entered when i run the code...
maybe this will give you some direction in your code?
:)
susan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top