title: VBA Code: How to Copy Rows & Create Sheets based on column data From MS Excel
body: <p>I am new in VBA and want copy rows of the following worksheet based on the value of column <strong>OFFICE</strong>:
  <a href="https://i.stack.imgur.com/pZ0Lb.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/pZ0Lb.png" alt="enter image description here"></a> </p>
  
  <p>So if you notice that there are 10 rows having 4 types of office: Office-A, Office-B, Office-C, Office-D (and so on,it could be more office types ).So i want a VBA code that dynamically creates as many new sheets based on number of types of office in OFFICE column and move the rows that matched with a corresponding office type into new sheet.For: here it will look at column OFFICE and create 4 new sheets, because there 4 types of data and move corresponding  rows to these sheets.Please help me to do that.Thanks</p>