Creating a list on a different worksheet/form

  • Thread starter Thread starter Jeff Frazier
  • Start date Start date
J

Jeff Frazier

We have developed a listing of inventory items with a cell associated with
each item that indicates if it is present. Is it possible to have the items
not present to be exported or listed on a different form or worksheet.
 
We have developed a listing of inventory items with a cell associated with
each item that indicates if it is present.  Is it possible to have the items
not present to be exported or listed on a different form or worksheet.

Yes, you can do something like this

Sub MOVETHEM()
Dim CELL As Range
For Each CELL In Range("B1:B50")
If CELL.Value = "NOT PRESENT" Then
CELL.EntireRow.Copy
Worksheets("Sheet2").Rows("65536").End(xlUp).Offset(1, 0)
End If
Next CELL
End Sub

I used range ("B1:B50") as the column that identfies if it's "PRESENT"
or "NOT PRESENT"
 
At the risk of sounding under-informed, can you point me in the direction as
to where that would be entered?
 
At the risk of sounding under-informed, can you point me in the direction as
to where that would be entered?





- Show quoted text -
Enter it in a module in VBE.
from excel push Alt+F11 then right click on your workbook on the left
side of the window and Insert/Module and paste that code in the screen
on the right with the module selected. after that, you should have a
macro by the name of "MOVETHEM" when you run that macro it will
perform the action
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top