Thread: Clear formulae
View Single Post
  #14   Report Post  
Posted to microsoft.public.excel.programming
Paul B[_6_] Paul B[_6_] is offline
external usenet poster
 
Posts: 135
Default Clear formulae

Tom, I used copy and paste values as you did with no problem, using excel
2000

--
Paul B
Always backup your data before trying something new
Please post any response to the newsgroups so others can benefit from it
Feedback on answers is always appreciated!
Using Excel 2000 & 97
** remove news from my email address to reply by email **
"Tom Ogilvy" wrote in message
...
No,

cells.copy
cells.pastespecial xlValues

doesn't have that problem.

At least not in xl97. What did you testing show and what version?
--
regards,
Tom Ogilvy

"Trevor Shuttleworth" wrote in message
...
Paul

thanks for raising this ... worth being aware of. The alternative

approach
of copy / paste special values would also have the same effect. I guess

it
can be avoided by cycling through the cells with formulae but I expect

this
would be a little slower than the original suggestion.

Sub FormulaeToValues3()
Dim cell As Range
For Each cell In ActiveSheet.UsedRange.SpecialCells(xlCellTypeFormu las,

23)
cell.Value = cell.Value
Next
End Sub

I don't think you can apply formatting to cells with a formula in them

so
this should be safe.

Regards

Trevor


"Paul B" wrote in message
...
Trevor, be careful with this one, don't know why but it looks like it

will
remove and super and sub scripts

--
Paul B
Always backup your data before trying something new
Please post any response to the newsgroups so others can benefit from

it
Feedback on answers is always appreciated!
Using Excel 2000 & 97
** remove news from my email address to reply by email **
"Trevor Shuttleworth" wrote in message
...
Stuart

one way:

Sub FormulaeToValues2()
With ActiveSheet
.UsedRange.Value = .UsedRange.Value
End With
End Sub

Regards

Trevor


"Stuart" wrote in message
...
Is there a simple way to clear formulae from the activesheet,

leaving
just the values in the cells ..... or do I have to do this cell by

cell
eg:
setValue = ActiveCell.Value
ActiveCell = setValue

Regards.



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.674 / Virus Database: 436 - Release Date: 02/05/2004