#1
|
|||
|
|||
Is it correct (PasteSpecial function)
Public Function sss(strCell) As String
sss=strCell.PasteSpecial End Function Selection.PasteSpecial Paste:=xlPasteValues I want to merge above two make pastespecial function? my idea is to get data with out formula |
#2
|
|||
|
|||
A FUNCTION() is by definition a formula. If it is used in a cell, that is.
However a macro can be invoked to run on the activecell. This macro will convert the current selected cells into flat values: Code:
Sub RemoveFormulas() Selection.Value = Selection.Value End Sub |
#3
|
|||
|
|||
Quote:
Public Function sss(strCell) As String sss=strCell.Font.Size End Function like that only i need, if i give =sss(a1) remove formula and give flat value |
#4
|
|||
|
|||
The normal formula =A1 will give you the "value" from cell A1.
There is not formula (or even User Defined Function) that causes another cell to lose it's formula. Only a regular macro can do that, not a function. |
#5
|
|||
|
|||
Quote:
i need that function |
#6
|
|||
|
|||
Quote:
If we're going to enter a formula into D1, then we might as well enter: =C1 |
#7
|
|||
|
|||
there is no such function =getflatvalue(c1)
|
#8
|
|||
|
|||
I know we are in a round robin here, you don't understand what I'm saying and I don't understand what you're trying to accomplish.
Based on everything you've said, if you want to enter a formula into D1 to get the "value" to appear that is the result of the formula in C1, then the formula to enter into D1 would be: =C1 There is no formula you can enter into D1 that will then delete itself leaving only the flat value behind. Formulas can only display values, they can't delete themselves. Only VBA can do that. |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Backup PST with correct folders | dmarques | Outlook | 2 | 06-04-2011 09:59 AM |
No scroll bar even though settings are correct | Lorretta | Word | 2 | 05-06-2011 07:31 AM |
Correct Format needed | TonyB | Mail Merge | 3 | 05-03-2011 01:10 AM |
So what is the correct value of PONT_STRING anyway? | DrDOS | Outlook | 0 | 11-21-2010 04:30 AM |
Auto Correct to Stay On | sanzlink | Word | 1 | 01-16-2009 06:49 AM |