PDA

View Full Version : Solved: Ignore error without converting to number



jazzyt2u
08-01-2008, 04:15 PM
Hi,

You know When you type 1. into a cell and it puts that green character in the upper left corner of the cell until you either select "convert to number" or select "ignore error". Well I need to keep the . after the 1 so what code do I need to make the green thing go away without converting to a number?

I ask because I'm going to copy as a picture and paste it into Word and when you do it as a picture it keeps all flaws...

mdmackillop
08-01-2008, 04:20 PM
Precede with an apostrophe. This forces the remainder to be inserted as literal text.

Bob Phillips
08-01-2008, 04:20 PM
Turn off background error checking, Tools>Options>Errorf checking, uncheck Enable background error checking.

Enter it as

'1.

jazzyt2u
08-01-2008, 04:24 PM
What about other's that use this spreadsheet... I thought about that but Will taking off the error checking on my end affect them...when they run this macro?

jazzyt2u
08-01-2008, 04:27 PM
Never mind. I see that it works per the spreadsheet... Thanks you two!!!!!!!!!!!

jazzyt2u
08-01-2008, 04:35 PM
Actually that didn't work because everyone who uses this document will have to turn their error checking off...

How do I take the solved off this post? LOL

Aussiebear
08-02-2008, 02:53 PM
Hi jazzyt2u, I have removed the "solved" for you. Have you tried MD's suggestion?

Bob Phillips
08-02-2008, 03:00 PM
Yould turn it off on sheet activate, and on on deactivate.




Private Sub Worksheet_Activate()
Application.ErrorCheckingOptions.BackgroundChecking = False
End Sub

Private Sub Worksheet_Deactivate()
Application.ErrorCheckingOptions.BackgroundChecking = True
End Sub


This is worksheet event code, which means that it needs to be
placed in the appropriate worksheet code module, not a standard
code module. To do this, right-click on the sheet tab, select
the View Code option from the menu, and paste the code in.

jazzyt2u
08-06-2008, 12:53 PM
Thanks I will give it a try!!!!!