Posts by Saftlad

    Re: Move Rows Based On Content Of 2 Cells


    Thanks Venkat. It seems to work fine in your example, but when I try to move it over into my own full file, it doesn't like it. As soon as I step once, Excel crashes.


    Could I send you my original file for you to see if you can identify where the problem lies?


    It may also help to understand what it is that I am trying to achieve in full.


    Thanks for your help either way.

    Re: Move Rows Based On Content Of 2 Cells



    If the supplier is not "supplier 1" or "supplier 2", thanks.

    Hi all,


    At the moment I have 1 spreadsheet with 12 worksheets that I have to enter data into. I would rather enter all the data onto one sheet then have a macro move the data into the correct worksheet based on the contents of columns A and B.


    Please find an example attached with dummy data.


    The raw data will be entered into the worksheet "Data". Once complete, I would like the user to press a button and the macro to then identify from column A the suppliers name. If it is not one of the recognised suppliers, then it would move the row into the worksheet "one off". If it does recognise the supplier then it checks column B to see which of the two supplier's two worksheets it needs to copy it to, with the data entered into the correct column based on the column title (ie only the white columns).


    Am I asking too much?


    Thanks for your help

    Files

    • Book1.xls

      (29.7 kB, downloaded 70 times, last: )

    Sorry to bother you all, but I have a somewhat large spreadsheet that I am working on manually, and I'm sure it could be done much more easily if automated.


    I have a list of items with a quantity in the final column. I need the rows to be copied the same number of times as the quantity displayed so that instead of having 1 row with a quantity of 5, it copies this row a further 4 times so that there are 5 rows.


    Can any shed any light on how this can be achieved other than manually as is currently the case?


    I've attached an extract so that you can see what I am working with.


    Column H holds the quantity (obviously) and ideally should be reset to 1 when the item is copied the relevant number of times.


    Thanks for your help.