I have a worksheet that has 3 sheets that are linked to each other.
I want to write a macro that deletes/adds a row in sheet 2 and sheet 3 when I delete/add a row in sheet 1.
Problem is that I never wrote a macro till now.
Please help.
I have a worksheet that has 3 sheets that are linked to each other.
I want to write a macro that deletes/adds a row in sheet 2 and sheet 3 when I delete/add a row in sheet 1.
Problem is that I never wrote a macro till now.
Please help.
You don't have to do this in VBA. Select the sheets you want by holding down the CTRL key as you click on them. Then whatever you do to one sheet will happen to all of the selected sheets. You can add, delete rows or columns, change formats, add data and validations and even enter formulas. It's called a 3-D formula.
One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.
A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.
Thanks for your response.
I tried grouping the sheets but it is not helping. I still insert a row on my first sheet, a blank row is not being inserted in my other to sheets.
Please suggest an alternative.
Did you have your so called first sheet included in the grouping?
What dflak described works like a charm (if you do it right).
Yes. I had the control key pressed and I selected all of my 3 sheets and grouped them.
I realized that there is an offset between the row I'm deleting in sheet 1 and the row that has to be deleted in sheet 2 and 3 so grouping is not helping.
Ex. I want to delete row 17 in sheet 1. When I delete row 17 in sheet 1, I want to have row 20 deleted in sheet 2 because row 20 in sheet 2 corresponds to row 17 in sheet 1.
I think I may need a macro for that. Please help.
Attach a sample workbook and tell us which rows on one sheet "map" to which rows on another sheet. E.G. If I delete a row on Sheet 1 I want the same row only three rows down to be deleted on Sheet 2.
The trick will be finding an appropriate "trigger" to make the event happen.
Attach a sample workbook (not a picture or pasted copy). Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.
Remember to desensitize the data.
Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks