Create Macro To Sort And Move Data

Jun 5, 2009

I have sheet 2 with a table with data in A2 thru X500, A1 thru X1 are my headers, A1 data is either Forecast or Sold, B1 data is Month, C1 is Value. I first need to Filter the data by Forecast, then by a specific month then by the value in decending order (keeping in line the data thru x which are headers I don't need to sort by). Next I need to take the 1st 10 lines by a specific month; A thru X and copy it onto a defined section on Sheet 1.

I then need to do this for the 2 more times for the 2 proceeding months. So If we start with Jan, I need the macro to do Feb and march as well.

The end result is that I have Sheet 1 with 3 sections on it each section is 10 lines and the resulting data is my top 10 forecasted deals for Jan, Feb, March. The macro must be able to do this for each month, so if June is chosen the 3 months are june, july and Aug.

View 9 Replies


ADVERTISEMENT

Sort And Move Code, Create Equipment Lists`

Mar 5, 2007

I have been using Excel to create equipment lists for my work. The forum has helped me by creating a visual basic macro to create a 'final list' sheet compiled from the other source worksheets.

On my 'final list' sheet I need the first 10 rows to be left out of the macro’s so that I can add header information like job reference etc. I have tried altering the visual basic code by adjusting the row numbers in it so that it starts at row 10 but this keep's on producing error codes. This is due to my limited knowledege of what each line does.

I also wish to be able to paste new equipment into the final list sheet. When I do this at the moment the code does not recognise it is there and does not carry the information accross back into the source sheet. It is the same when I block select an area and delete the code does not recognise I have done this which is fustrating.

View 4 Replies View Related

How To Create Macro To Move Multiple Horizontal Data To Vertical

Jul 23, 2008

I need to create a macro to move variable multiple horizontal data to vertical format with certain infomation on horizontal will be duplicated following that variables. It's looks like below where you can see variables data in column F, G, H and I are moved vertically and at the same time column A, B, C, D and E will be duplicated following the variables allocation. I've tried to use transpose but it too manual and now looking suitable macro to help on this function

Original DataAccountDim 3Dim 4AmountCurrencyV20228V20242V20211V202044006003300BXXX 9.4USD0.591.923.343.554006003400BXXX 88.17USD5.5118.0331.3233.314006003500BXXX 7.27USD0.451.492.582.75Process to automateAccountDim 2Dim 3Dim 4AmountCurrency400600V202283300BXXX 0.59USD400600V202283300BXXX 1.92USD400600V202283300BXXX 3.34USD400600V202423300BXXX 3.55USD400600V202423400BXXX 5.51USD400600V202423400BXXX 18.03USD400600V202113400BXXX 31.32USD400600V202113400BXXX 33.31USD400600V202113500BXXX 0.45USD400600V202043500BXXX 1.49USD400600V202043500BXXX 2.58USD400600V202043500BXXX 2.75USD

View 9 Replies View Related

Macro To Create Pivot Tables And Sort Out Data In Other Worksheet

May 19, 2009

The first sheet is the row data given to me, the second one is where I want my data to be analysed automatically by macros.

I managed to create a pivot table manually to give me the info I want but then I still have to copy all the results from the pivot table sheet to my analysis sheet.

How can I create a macro able to do all that by it self? I tried to record a macro using the recorder but then when I try to play it it gives me an error straight at the beginning in the definition of the pivot table I think.

An example of what I want the pivot table to do is:
in the first sheet, go in the small table in column K and L, take the value of L1, then in the row data in column A to J, in column C look for the value in L1, once found, look for the value 1 in column J then do the average on the values in column E and put the result in my second sheet in cell F5
then do the same but look for 2 in column J and put it in F8, then 3 in F11, ... until 7 found (the data is in ss.000 and so the results in the second sheet should be formated the same way)
then do the same all over again for value in L2
etc etc etc

this should be done for the 6 values in column L, each having values up to 7 in the J column.

Then I need to do the same for other columns and not only averages but minimums as well but I can adapt the code I think.

View 14 Replies View Related

Sort / Move Data In Accordance To Specific Column?

May 9, 2014

How to do what I am about to ask takes time and time causing brain overloading. I have made screenshots but I can't upload them. I get red exclamation point with images sizing ~55KB

View 9 Replies View Related

Move And Sort With One Column But Insert Extra Columns As Needed For Proper Sort?

Jan 13, 2014

Using DataEntry sheet for data.
Trying to rearrange the data to DataFormatedProperly sheet.
So far all I can accomplish is DataFormatedWrong sheet.

Edit: Not sure what happened but file was NOT understandable before. It should be correct now.

View 2 Replies View Related

Create A New Worksheet And Move All Data Below And/or To The Right Of That Cell To The New Sheet

Oct 31, 2007

situation: 3 rows of data, row 1 has HDR in several cells (always in A1).

task

1. search row one for next example of cell containing HDR, excluding cell A1.
2. IF found, create a new worksheet and move all data below and/or to the right of that cell to the new sheet.
3. Repeat steps two and three until the search does not turn up another HDR except in A1.

View 9 Replies View Related

Sort Different Columns Separately And Create Combobox To Filter Data?

Jun 6, 2014

I have a workbook has a "Summary" worksheet. I would like to be able to do the following:

(1) Sort columns D, G, J, M,... (the number of columns are different each time I run the macro that I have).

(2) create a combo box to be able to the data (that sorted in 1) by month (1,2,..., 12).

see the attached file

View 5 Replies View Related

Excel Macro To Move Data From One Sheet - Search Another And Paste Data

Mar 28, 2014

I have two worksheets. Sheet 1 has 2 columns, Column A the restaurant's name and Column B contains the review score. So sheet 1 is kinda like this:

Restaurant |Score
Ruby Tuesdays 80
TGIF 78
Outback 92

Sheet 2, Row 1 column B-E contain restraurant names (only on the top row, like field names).. i.e. I manually put the date in because typically the projected date is different from the actual review date.

-A----------- B ----------------C ------D-------- E-----
Date |Ruby Tuesdays|Olive Garden|TGIF|Ruths Chris|

I need the data from Sheet 1 Column B moved to sheet 2 in the next open row (i currently have data in row 1..the field names and down to row 35). This will be continuous so each time i need it to add the score as a new row in the correct field (restaurant name), IF the restaurant isnt listed, I want a new field named with the restaurant name and then place the score in the correct row and column. So, in the example I'd need Outback added.

View 9 Replies View Related

Macro To Move Data From Data Entry Update Master Sheet Using Formula To Allocate

May 12, 2013

I am working on a project and would like to see if there is a solution for it. i have a workbook that has data entry that is summarized at a master level but I need to automatically use a formula to update another sheet after clicking an udpate button. The data from the data entry sheet needs to be allocated to all the lines that has the same master item based on the formula. A test workbook is attached ...

View 1 Replies View Related

Move To Next Column After Sort

Mar 24, 2007

Need the formula that I will need in my macro to move to the next column (up one letter) for the next time I run the macro witout me having to manually change column the letter?

View 15 Replies View Related

Two Column Sort And Move

Mar 13, 2009

I have a look up table on sheet 1, that looks like this table to the right. On sheet 2, I need it to find the table contents in the column CC, then look at a column AA and find all that match it and move all that match this cell in column AA and copy the row it to sheet 3.

Its 300 lines of data, a couple of time of week.

It is a sort of data with a twist.

AABBCCDDEETreeDogCathousecardavemanboyjobbaseTableboatsamlaurasamjimboydaveweedwalkwalkruncatfunlaughboydivefloatTreeDogCathousecardavemanboyjobbasedaveweedwalkwalkrunfunlaughboydivefloat

View 9 Replies View Related

Sort, Average & Move

Jul 16, 2007

I am a buyer of hundreds of different types of items. I get thousands of different price quotes each day for hundreds of different items, 3 of which are balls, gloves and bats. I don't have the time to go line by line through thousands of quotes for hundreds of items each day to find the best deals. I want Excel to point the best deals out to me automatically, perhaps by making a cell.

Basically I need excel to sort my data by item type.

Then, calculate the average price for each item.

Then, point out any price quotes that are 10% below the average price, perhaps by making that quote in a red box. Attached is a spreadsheet with an example.

View 6 Replies View Related

Macro To Move Data To Another Format

Feb 25, 2014

I'm looking for a macro to select data from a larger data set, and then put it in another worksheet. Basically, I want to select any cell in column A that contains "SO5" and move those to the column A of a separate worksheet. Then, for each cell that contains "SO5" would like to move to the right 5 columns and down 3 rows and select from that cell all the way to the end of the table. There may or may not be data in all of the table cells, so the selection should be based off of the column headers which will always have values. I would like to take that data and put it with the corresponding "SO5" in the new sheet.

Here's a sample:

MacroSample.xlsm

This is a simplified version, but I'm trying to get the data from sheet1 into the format in sheet2. Keep in mind that the number of columns and rows may change so it needs to be as dynamic as possible.

View 1 Replies View Related

Macro To Move Data From A Cell Into New Row

May 12, 2014

I have an issue with groups of data in a row, that I need to copy into a new row beneath the original. I need a formula or VBA that will perform this function:

If any data is present in columns AG-AK, then copy that data into a new row below, into cells AB-AF. Also copy column B (this data is always present, it is the name of the project data contained in the original row)

If any data is present in columns AL-AP, then copy that data into another new row below, into cells AB-AF. Also copy column B (this data is always present, it is the name of the project data contained in the original row)

View 3 Replies View Related

Macro - Move Data From A Number Of Sheets

Sep 3, 2007

Im trying to do a macro that will move data from a number of sheets based on a flag in column W on each sheet.

Basically if the flag in column W is "YES" then i want it to copy the whole row and append it (if thats possible?) into the sheet 'Journal'

I have attached a cut down version with only 3 sheets (one of which is the 'Journal' sheet) and only a few rows on each sheet.

View 10 Replies View Related

Macro To Move Data With Trigger Cell

Feb 21, 2010

I have a single workbook with five spreadsheets. My goal is to move data along a path (or work flow) from one sheet to the next by using a "trigger" pulldown menu choice.

Sheet1 = Prospects
Sheet2 = New Sale
Sheet3 = Upgrade Sale
Sheet4 = Won
Sheet5 = Lost
Sheets 1, 2, and 3 use the same data layout for column A - K.
Sheets 4 and 5 have the same A - K as above and also have columns L - R in common.
The last column in sheet 1, 2 and 3 is a pulldown menu (New, Upgrade, Won, Lost).

Data rows on each sheet start at row 7.

The goal is to use the pulldown choice to remove the data from the current sheet (ex: Prospect) and add it to the next open row in the required sheet (ex: New or Upgrade). I also need to be able to make a similar move from New/Upgrade to Won or Lost.

View 11 Replies View Related

Macro To Move Data From Excel To Word

Apr 24, 2012

I have data in a single Excel worksheet, single tab, columns A:C.

I want to move that data into Word.

The format in Word:
Contents of A1
Contents of B1
Contents of C1
Blank Line
Contents of A2
Contents of B2
Contents of C2
Blank Line
etc, etc, etc, etc....for all rows in Excel.

View 9 Replies View Related

VBA Macro To Move Data To Adjacent Cell

Mar 26, 2013

writing a Macro which will move data from a cell to an adjacent cell.

E.g Column B has only data in certain cells, I would like the Macro to work down the column and every time it encounters data in Column B to move it into the adjacent cell into Column A.

View 4 Replies View Related

Auto-Move Macro Button Down With Data

Oct 29, 2013

My data is now 500+ lines long but the button is on row 1. I have to get back to the top to click it. Can I auto move the button down with my data. Say to one line above my data. i.e. 499 and move as my data increases.

View 3 Replies View Related

Macro To Move Data From One Worksheet To Another In Same Workbook

Jul 22, 2009

Is it possible to have a macro compare two wokrsheets and move the totals from one sheet to the other worksheet.

Here are the worksheets: ....

View 9 Replies View Related

Macro To Sort The Data

Jun 27, 2009

I need to sort the following data by the CODE number shown while keeping the Description and Quantity attached to the various codes. (Excel is smart enough to first sort the codes numerically then alphabetically, which is what I need) The client info (bottom) also needs to be left alone. Done correctly, after running the macro, the order would be 04cls, 04fba, 08jud, with the Desc. and Quantities moved with the codes. At the moment each line is stored in a single excel cell.

Description = Item1
Code = 08jud
Quantity = 1

Description = Item2
Code = 04fba
Quantity = 1

Description = Item3.........................

View 9 Replies View Related

Automatically Move & Sort Row Based On Cell Value

Sep 20, 2008

I have a simple projectlist on sheet1 formatted like this:
Column A=Projectname, B=Description, C=Owner, D=Deadline and E=Status.
On sheet2 I have the same columnheaders.

What I would like to do, is that if Status changes to "Done",
* the entire row should be copied to a free row on sheet2, or just inserted on sheet2.row2 without overwriting anything
* the now empty row on sheet1 should be deleted (so there're no empty rows)
* the data on sheet2, should be sorted with D as first key and C as second.

Then, if Status on sheet2 changes to "Reopened", the same procedure should happen but from sheet2 to sheet1.

My first choice was to create a checkbox on each row in the Status column,but I noticed it didn't seem to follow with cut/paste even though I changed the property Locked to false. Anyone knows if it's possible to change this behaviour?

I only know small bits of VBA but my idea is this: ...

View 4 Replies View Related

Macro To Move Data From One Sheet To Another And Separate 1 Cell Into 2?

Mar 25, 2014

I have a worksheet that has time clock information. I also have a resource on the web to see some information and even export it. In the exported data it looks as follows:

A1 contains an individuals name
B1 says times i.e. "8am to 5pm"

I would like a macro that takes the data from A1 and moves it to another worksheet in the B4 position down, and take the times from B1 and move the first time to the C4 position and the last time to H4.

View 9 Replies View Related

Macro Click Button To Move Data To Table

Apr 13, 2013

This is the macro I am using

Sub Macro3()
'
' Macro3 Macro
'
Range("C2").Select
Selection.Copy
Sheets("Table").Select
Range("A1").Select
Selection.End(xlDown).Select
ActiveCell.Offset(1, 0).Range("A1").Select

[Code] .....

It does everything I want but take F2 info and send it over. But F3-F6 does go over.

View 6 Replies View Related

VBA Macro To Move Data To Summary Sheet Based On ID's

Nov 5, 2009

I have had several intro programming classes, but not with visual basic. I've noted the problem lines with comments below. The problems are probably very easy syntax error.

Sub list()

Dim counter As Integer
Dim counter2 As Integer
Dim id As Double
Dim id2 As Double
Dim palletnum As Integer

ActiveSheet. Name = "Pallet Detail"
Sheets.Add
ActiveSheet.Name = "Pallet Summary"
Sheets("Pallet Detail").Select

View 7 Replies View Related

Macro To Sort And Delete Data

Mar 31, 2008

I am looking for a macro to do the following:

Once data is copied to a tab labeled "data", it will sort on column H and delete all rows of data that do not have a AI or an RI code on it. Is this difficult to do?

View 9 Replies View Related

Macro: Sort Data Around Selection

Dec 22, 2006

how to sort a selected range.

The end of the range could be any cell. The top of the range is fixed in A1.

I've tried with this:

Sub Order()
Dim final As Variant
final = Selection.End(xlUp).Address
Range("A2").Select
Range("A1:" & final).Sort Key1:=Range("C2"), Order1:=xlAscending, Key2:=Range _
("G2"), Order2:=xlAscending, Header:=xlGuess, OrderCustom:=1, MatchCase _
:=False, Orientation:=xlTopToBottom, DataOption1:=xlSortNormal, _
DataOption2:=xlSortNormal
End Sub

View 9 Replies View Related

Macro Code To Sort Data

Jun 29, 2008

i want to create a command button that would sort my data in descending order.

View 7 Replies View Related

Excel 2010 :: Macro - Move Data From Rows To Columns

Dec 13, 2011

I am using Excel 2010 and need a macro that can convert data from rows to columns. I have read several posts about this subject but have no experience with macros and don't know how to change the macros to fit my scenario.

Here is what I currently have:

Account...Vehicle1...Loc1...Vehicle2...Loc2...Vehicle3...Loc3...Vehicle4...Loc4
11111......2008........FL
11111......2000........FL
12121......1999........GA
33222......2000........AL
33222......2011........AL
33222......2001........MS

Here is what I need it to look like:

Account...Vehicle1...Loc1...Vehicle2...Loc2...Vehicle3...Loc3...Vehicle4...Loc4
11111......2008.......FL.......2000........FL
12121......1999.......GA
33222......2000.......AL.......2011........AL......2001.......MS

There are up to 4 vehicles/locations per account number, and I need 1 account number per row (the dots above are for spacing only and not part of the actual data).

I could do this manually but because I have so many rows of data it could take days or weeks. Is there a macro out there that can do this??

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved