LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Copy down missing data

Thanks Jim for pointing that out..

Dave, The below method will work only if the cells are genuine blanks...(if
the data is imported from some other source it may not be the case.)

--Select a unused cell say E2
--Enter the formula in cell E2 which references the top cell (=E1)
--Copy the cell
--Keeping the copy select the data range in ColA and ColB
--Press F5. From Goto window select blanks
--This will select all blanks.. Now Right clickPasteSpecialFormulas. will
fill in with the data you need..
--Once done you can select col A Copy PasteSpecialValues to turn
formulas to actual values

If the above doesnt work then try the below macro..

Sub MyMacro()
Dim lngRow As Long
For lngRow = 2 To Cells(Rows.Count, "C").End(xlUp).Row
If Trim(Range("A" & lngRow)) = "" Then _
Range("A" & lngRow) = Range("A" & lngRow - 1)
If Trim(Range("B" & lngRow)) = "" Then _
Range("B" & lngRow) = Range("B" & lngRow - 1)
Next
End Sub



If this post helps click Yes
---------------
Jacob Skaria


"Jim Thomlinson" wrote:

Shouldn't they have copied the formula at some point???

Select Cell A3
Select the columns A:C
F5 - Special... | Blanks
(all blank cells should now be highlighted)
Type = <up arrow
Ctrl + Enter
Copy PasteSpecial Value
--
HTH...

Jim Thomlinson


"Jacob Skaria" wrote:

Enter the formula in say J2
=J1

Select column A.
Press F5. Click Special
From GoTo window select Blanks.
Right clickPaste SpecialFormulas..

If this post helps click Yes
---------------
Jacob Skaria


"Dave Shultz" wrote:

I want to write a macro to copy down €śHoliday€ť in column A until the row
where €śVacation€ť appears. And then copy down €śVacation€ť in the subsequent
rows. And the in column B, I want to copy down €śTeam A€ť until the next team
is mentioned. However, I dont want the macro applied to the columns where I
have the # of hours listed.

Suggestions?

Type Team Name Jan Feb Mar Apr
Holiday Team A Tom 16 8
Dick 16 8
Harry 16 8 12
Team B Sue 16
Kim 16 8
Sam 16 8
Team C George 16 8
John 16 8
Jim 8
Vacation Team A Tom 8
Dick 8
Harry
Team B Sue 8
Kim
Sam 8
Team C George 8
John 8
Jim

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
connect line to data points with missing data in between ziak Charts and Charting in Excel 4 April 4th 23 10:35 AM
Missing Cloumn data when importing external data Findus Excel Discussion (Misc queries) 0 December 16th 08 11:22 AM
How to determine the cause of missing data after I importing data LMonro Excel Discussion (Misc queries) 7 October 26th 07 04:00 AM
Missing text from copy/paste Malora Excel Discussion (Misc queries) 1 September 14th 06 06:13 PM
FOUND LOST FILE BUT COPY IS MISSING NITRAM RENRAS Excel Worksheet Functions 0 January 26th 06 08:03 PM


All times are GMT +1. The time now is 02:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"