PC Review


Reply
Thread Tools Rate Thread

Delete rows but keep formatting to 1000

 
 
Jock
Guest
Posts: n/a
 
      1st Oct 2009
A worksheet has 1000 formatted rows some of which contain formulae.
A macro will remove entire rows when certain criteria is met and paste to a
different sheet.
When this happens, the number of formatted rows decreases in number by the
same amount that have been moved.
How can I ensure that I always have 1000 rows regardless of how many rows
are removed?
--
Traa Dy Liooar

Jock
 
Reply With Quote
 
 
 
 
Jacob Skaria
Guest
Posts: n/a
 
      1st Oct 2009
--One way is to clearcontents rather than deleting the row. But you will have
to clearcontents for the cells without formulas and end of the macro you will
need to sort the range to bring the records together

--Another way is to recreate or copy the formats using pastespecial and fill
formulas into new rows to keep that to 1000.

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


"Jock" wrote:

> A worksheet has 1000 formatted rows some of which contain formulae.
> A macro will remove entire rows when certain criteria is met and paste to a
> different sheet.
> When this happens, the number of formatted rows decreases in number by the
> same amount that have been moved.
> How can I ensure that I always have 1000 rows regardless of how many rows
> are removed?
> --
> Traa Dy Liooar
>
> Jock

 
Reply With Quote
 
Per Jessen
Guest
Posts: n/a
 
      1st Oct 2009
Hi Jock

How does the macro 'remove' rows?
If you use Cut/Paste, then you can just use Copy/Paste and then use
..ClearContents to clear data afterwards.

Post your macro for further help.

Regards,
Per

"Jock" <(E-Mail Removed)> skrev i meddelelsen
news:244394F6-B29A-4F1B-B5DB-(E-Mail Removed)...
>A worksheet has 1000 formatted rows some of which contain formulae.
> A macro will remove entire rows when certain criteria is met and paste to
> a
> different sheet.
> When this happens, the number of formatted rows decreases in number by the
> same amount that have been moved.
> How can I ensure that I always have 1000 rows regardless of how many rows
> are removed?
> --
> Traa Dy Liooar
>
> Jock


 
Reply With Quote
 
JLGWhiz
Guest
Posts: n/a
 
      1st Oct 2009
Copy and paste wiith subsequent clear contents for souce range will save the
format, but not the formulas. The formulas will have to be re-done if you
want them in their original locations. But you could have a macro that does
that for you.



"Jock" <(E-Mail Removed)> wrote in message
news:244394F6-B29A-4F1B-B5DB-(E-Mail Removed)...
>A worksheet has 1000 formatted rows some of which contain formulae.
> A macro will remove entire rows when certain criteria is met and paste to
> a
> different sheet.
> When this happens, the number of formatted rows decreases in number by the
> same amount that have been moved.
> How can I ensure that I always have 1000 rows regardless of how many rows
> are removed?
> --
> Traa Dy Liooar
>
> Jock



 
Reply With Quote
 
Rick Rothstein
Guest
Posts: n/a
 
      1st Oct 2009
It might help if you showed us your code (at minimum, the part that test the
criteria and "removes" the entire row).

--
Rick (MVP - Excel)


"Jock" <(E-Mail Removed)> wrote in message
news:244394F6-B29A-4F1B-B5DB-(E-Mail Removed)...
>A worksheet has 1000 formatted rows some of which contain formulae.
> A macro will remove entire rows when certain criteria is met and paste to
> a
> different sheet.
> When this happens, the number of formatted rows decreases in number by the
> same amount that have been moved.
> How can I ensure that I always have 1000 rows regardless of how many rows
> are removed?
> --
> Traa Dy Liooar
>
> Jock


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Copy Top 10 conditional formatting down 1000+ rows AdrianTCP Microsoft Excel Worksheet Functions 1 14th May 2010 02:29 AM
How can I use conditional formatting to hide or delete rows? =?Utf-8?B?bGluZGEuYmVhdXRpZnVsLmNhbGlmb3JuaWE=?= Microsoft Excel Worksheet Functions 6 15th Jul 2008 09:09 PM
Macro to keep 15 specific records and delete 1000 other rows. Sam Microsoft Excel Programming 6 23rd Oct 2006 12:04 AM
Macro to keep 15 specific records and delete 1000 other rows. Sam Microsoft Access Macros 1 22nd Oct 2006 09:12 AM
Find the nearest point to 1000 rows where "amounts" balance and apply special formatting to that row Paul Microsoft Excel Programming 4 14th Oct 2005 05:02 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:10 PM.