Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 103
Default Delete rows and refs

I am wondering if there is a macro that can be written that will delete a row
and also any reference to any cells in that row from froumulas on the sheet.
For example: A1=B1+B2+B3 i then delete row 2 and get A1=B1+#REF+B3, i would
like to get A1=B1+B3. Is something like this possible? Maybe when running
the delete row macro it would do a find and replace? Any thoughts? Thanks

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200705/1

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Delete rows and refs

look at DirectPrecedents property of the cell to be deleted before you delete
it. Loop through them and change the formula.

--
Regards,
Tom Ogilvy


"brownti via OfficeKB.com" wrote:

I am wondering if there is a macro that can be written that will delete a row
and also any reference to any cells in that row from froumulas on the sheet.
For example: A1=B1+B2+B3 i then delete row 2 and get A1=B1+#REF+B3, i would
like to get A1=B1+B3. Is something like this possible? Maybe when running
the delete row macro it would do a find and replace? Any thoughts? Thanks

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200705/1


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 103
Default Delete rows and refs

I am trying to streamline a process. I have a sheet with with rows that have
cells that contain formulas. Some of those rows get deleted while using the
sheet however there are a group of cells that refrence some of those cells.
i would like to be able to right click the row and instead of Delete Row it
would be Delete row and References and that would take care of the problem
for me. It would be a lot quicker than cycling through formulas and changing
them. Ideas?


Tom Ogilvy wrote:
look at DirectPrecedents property of the cell to be deleted before you delete
it. Loop through them and change the formula.

I am wondering if there is a macro that can be written that will delete a row
and also any reference to any cells in that row from froumulas on the sheet.
For example: A1=B1+B2+B3 i then delete row 2 and get A1=B1+#REF+B3, i would
like to get A1=B1+B3. Is something like this possible? Maybe when running
the delete row macro it would do a find and replace? Any thoughts? Thanks


--
Message posted via http://www.officekb.com

Reply
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
auto-hide rows, cell format (# and @), update cell refs, shade cel Mo2 Excel Discussion (Misc queries) 0 April 17th 07 03:44 AM
Cut filtered rows, paste into next empty row of new sheet, and delete cut rows Scott Excel Worksheet Functions 0 December 13th 06 01:25 AM
How do I fix cell refs when adding rows Dave L Excel Discussion (Misc queries) 5 December 2nd 05 09:52 PM
How to delete rows when List toolbar's "delete" isnt highlighted? Linda Excel Worksheet Functions 1 May 26th 05 08:39 PM
Delete every 3rd row, then delete rows 2-7, move info f/every 2nd row up one to the end and delete the row below Annette[_4_] Excel Programming 2 September 21st 04 02:40 PM


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

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

About Us

"It's about Microsoft Excel"