LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #19   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,101
Default Moving Info from onw sheet to another

I am a MACRO making fool. I am getting it to everything I need it took a
while to get the exact coding and order down but I am getting there... I just
hope there is not a limit of lines of code I can put into a macro. LOL!!!! My
first Macro has about 308 lines of code...LOL!!!!!!

"JP" wrote:

Check out the thread "Extract Whole Row If Q" in the
microsoft.public.excel.programming group, you will need some more
macro expertise to debug and implement this code for your project.


HTH,
JP


On Jan 10, 1:26 pm, Mike wrote:
Thanks JP But I dont think you understand what I trying to do. Dont get me
wrong Thank you SOOO MUCH for all your help. If I ramble I am sorry.. I am
trying to set up a filter that can take the info from the (Sort Sheet) Where
the info is stored. Sort it By Piers (Which there are 16 of them) to each
pier having its own sheet With it's own headers and footers. and do this
without having to copy and paste. I will see what this you code you gave can
do.

Thanks again
Mike



"JP" wrote:
This updated code will add the header and footer to the new worksheet.
It assumes that the footer text is in the worksheet in a range
A100:G103. If you put this text somewhere else, simply adjust the
range in the macro.


Sub autofiltvisibleandcopytonewwkbk()
Dim rng As Excel.Range
Dim rng2 As Excel.Range
Dim NewSht As Worksheet


Set rng = ActiveSheet.UsedRange.Rows
' adjust the line below to fit your worksheet
Set rng2 = Range("A100:G103")


With rng
.AutoFilter Field:=6, Criteria1:="13"
End With


With ActiveSheet.AutoFilter.Range
On Error Resume Next
Set rng = .Resize(Rows.count, _
Columns.count).SpecialCells(xlCellTypeVisible)
On Error GoTo 0
End With


Set NewSht = Sheets.Add
rng.Copy NewSht.Range("A1")


rng2.Copy NewSht.Range("A65536").End(xlUp).Offset(2, 0)


End Sub


On Jan 10, 12:36 pm, Mike wrote:
WOW!!!!!!!!!!!!!!!! This is really starting to come together... BUT one other
question. Suppose I already have a sheet formated (i.e) with headers and
footers set. How do I get the macro to put the info onto that sheet? or is
that asking to much??? LOL


Thank you SOOOOOO Much JP- Hide quoted text -


- Show quoted text -



 
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
Moving last info in column of worksheet to another in same workboo sodat96 New Users to Excel 6 November 23rd 07 11:26 PM
Automatic moving cell Info Troy Excel Worksheet Functions 2 May 1st 07 12:00 AM
IF function? Moving the same info from one worksheet to another. Naomi Excel Worksheet Functions 3 October 26th 06 07:46 PM
How do you perform lookups when the info is always moving? Jeze77 New Users to Excel 3 March 31st 06 03:42 PM
How do I compare info in on sheet to info in another? Fanney Excel Discussion (Misc queries) 7 February 25th 06 02:16 AM


All times are GMT +1. The time now is 03:41 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"