![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Board Regular
Join Date: Apr 2002
Posts: 130
|
I have the following:
A1=0.5 A2=2 A3=3.2 A4=7 A5=3 I want to find all numbers in column A that have decimal points and paste them into Column B. I could not configure if statement with wildcard *. statement.... Could someone help, thank very much in advance! |
|
|
|
|
|
#2 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Austin, Texas USA
Posts: 11,654
|
=IF(MOD(A1,1),A1,"")
|
|
|
|
|
|
#3 |
|
Board Regular
Join Date: Apr 2002
Posts: 130
|
Mark ,
I pasted this code into B column but it is not populating the cells with the decimal data |
|
|
|
|
|
#4 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: Austin, Texas USA
Posts: 11,654
|
Quote:
{0.5,0.5 ;2,"" ;3.2,3.2 ;7,"" ;3,""} What are you getting? |
|
|
|
|
|
|
#5 |
|
New Member
Join Date: Apr 2002
Posts: 17
|
It does work! I've just tried it. Try having a go again!
|
|
|
|
|
|
#6 |
|
Board Regular
Join Date: Apr 2002
Posts: 130
|
Mark thanks a million, you were right on, my fault
|
|
|
|
|
|
#7 |
|
Board Regular
Join Date: Apr 2002
Posts: 130
|
Is there a quick way to remove the empty cells and compact column B?
|
|
|
|
|
|
#8 |
|
MrExcel MVP
Join Date: Feb 2002
Location: The Hague
Posts: 50,317
|
Insert 3 rows before the row where the data start: The data should look like this:
{""; ""; ""; "Vals"; 0.5; 2; 3.2; 7; 3} where "" blank cell. In A2 enter: =MOD(A5,1)>0 Activate A5. Activate Data|Filter|Advanced Filter. Check "Copy to another location". List range should be $A$4:$A$9, if not adjust. Enter $A$1:$A$2 as Criteria range. Enter $B$4 for Copy to. Activate OK. |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|