I have data in several files named APT1, APT2, APT3, APT4, APT5... then I have a master file called APTMASTER. the fles contain certain data in sheet 1, what I need to know is if there is a macro that can copy data from all the APT 1 to APT 5 in the APTMASTER in such a way that it is one continous flow of data. Can this be done by just a button...
I've got a spreadsheet made up of a Document Map and 100 sheets. I'd like to copy each sheet to its own file while retaining the name of each sheet, but I can't figure out how to retain the name- I get "Book 1" instead.
I am working on a file that has multiple worksheets with many links, lookups and formulas; some between the worksheets and some external to another Excel file. The plan is to use this file as a template and copy it over and over with new names. Once I save the file as a new name in a new folder on my network, will I lose all these links, lookups and formulas? Or is there a way to maintain the links or do a global change of the formulas (i.e., the original file name is "TEMPLATE" and the new file name is "PROJECT!1")?
I have 20 files with the same exact format. I want to copy two cells from each file (G26, G52) into another worksheet. Unfortunately, all of the files have the same name, so I guess I have to rename them all manually (1,2,3,etc.). Any code that will copy the results and paste them into A2,A3 and then go down the column based on the "name" (1,2,3, etc) of the open files?
I am having some 100 excel files in a folder. I need to copy specific values in those files to another new excel file. The file names are like file_0.xls,file_1.xls.....etc and the range to paste those values are like B1, B51,B101...etc...
I got the code for one file. Now i need to increment the final name and pasting range.
Copying data that is in one coloumn in an unsorted order to another file where I have the values in a specific order I want. There I want it sorted in a new row each time I click a button in the first file.
I have a script that does this in a new column each time. I need it in a new row in a table to keep the graphs auto updating without having to use a macro in the end file. Current VBA that copies it to a new column instead of a new row in the table (modified to remove file names).
How the current VBA works. It refreshes the file it is in to update the data from SQL, then opens the other file, copies it over using sumif compared to the first coloumn in the file. Adds the current date, copies everything it added and replaces it with values so the formula isn't kept once it saves and closes the file. It then saves the start file and stops.
I need to open each workbook, copy Sheet1, paste to next available Sheet# in Combined.xls, close the workbook and move to the next workbook.
I have the code for copying a specific sheet from one workbook to a new workbook. But I do not have the code which would perform the above mentioned task for me and I don't have any idea for how am I going to do this without your help
I have used the Search option to find out if this question had already been answered but I could not find a solution for this specific request
1) left click on tab 2) move or copy... 3) move selected sheets to book (File: Region 1.xls) 4) then go on to next tab...............
Now, this does loop through the requested files, I can see them open, then close. I'm guessing they are copying, but I take it that I need to have it paste, then go to the next? (The c:files is just generic, as the files are on our LAN, and I'm just paranoid. The "Erie St. Clair" are the actual names of the file, and the tabs).
I have about 100 files with using date as file name (ie. 08.20.07.xls, 08.21.07.xls, 08.22.07.xls....etc) Each file contain exact same # of fields (Columns) but varying number of rows. I would like to have a macro in my "Consolidated.xls" file to go through each file and put them into a single sheet with the first column as date field (source file name)
Example:
08.20.07.xls contains
First Name Last Name DOB John Doe 11/1/77 Jane Doe 12/1/78 "" "" ""................
I have a workbook "revision.xls" i have two excel workbooks "A.xls" and "B.xls" in a folder ( revision ) in my desktop. the location of this folder is " C:Documents and SettingskrishnaDesktop evision )
Both the excel files inside this folder ( "A.xls" and "B.xls" ) have columns B to F in each of them filled with some data.
The no.of rows upto which the data is filled in these two files can vary.
What i want is a macro which can open both these files automatically and can copy the contents in column B to L in both these excel files into revision.xls in such a way that the column B TO L of the excel file alphabetically first in the folder has to be copied to A to K column of revision.xls then after leaving one column blank i.e leaving L blank column ,the column B TO L of the excel file alphabetically 2nd in the folder has to be copied to M to W column of revision.xls.
I'm having problem in copying the data from 2 notepad files into a single excelsheet, i have the below macro which creates two seperate excel sheets. i want to put the data from summary1 to tab1 and summary2 to Tab2....
I have about 200 excel files all with the same layout as they are questionnaire answer forms, all I want from them is the information from 1 Column: Column C. I want to copy the information that is in Column C of all 200 files into 1 worksheet, each column next to each other in the worksheet so I can just scroll along and see all answers next to each other.
Is there any way to easily do this? At the minute I am manually pasting the column I want into my worksheet but this is taking too long.
I receive around 40 emails per day, all in the following format:
Subject: "Team x.x - date" Body text: "x files sent"
where x represents a number.
What I'm hoping to be able to do is drop all these emails into a folder (in .msg format), and use excel to look through them and extract the team number from the subject, and the number of files sent from the body text for each message.
Unfortunately, while I class myself as reasonably competent with excel vba, working with emails or .msg files is new to me, so I genuinely haven't a clue how to do this, or if it's even possible.
How do I write a vb macro that copies everything from multiple files, including sheets within files, and puts them into one master file. Here's what I have so far. I used a script from gnaga that worked great but it didn't copy seperate sheets. If you can help me out, I would greatly appreciate it.
Sub MergeSheets() Dim SrcBook As Workbook Dim fso As Object, f As Object, ff As Object, f1 As Object
Application.ScreenUpdating = False Set fso = CreateObject("Scripting.FileSystemObject") Set f = fso.Getfolder("C:Temp") Set ff = f.Files
I have about a thousand Excel timesheets that all contain 'hours worked' data in a column. Each row contains the area of the project they have worked on and therefore the amount of time they have spent on it. The timesheets also contain the person's name and a w/e date.
I want to sequentially work through each timesheet held locally in a single folder and copy the person's name, w/e date and the hours held in the column into a single new spreadsheet. I need to transpose the data so each amount of time spent on an activity ends up in a column.
I have attempted to record a macro for this but each time I try and run it after the intitial run, it moves to a completely different cell or set of cells to the ones I have directed it and consequently there is no data copied to the new sheet.
I believe this is the first problem..! The second is working through a high number of spreadsheets held in a single locattion but whilst browsing this site I saw the "Excel VBA Loop Through a Folder of Excel Workbooks" page and think this should work fine.
I have a lot of files with data that i need to copy into a master file.
I could open each file copy the data i need and paste it into the file. But I know there must be a way to do a loop macro.
All the files are labled "Sauce Data "Date"". all the data is in the same place in each file. I can easy have a list of all these file names in a tab in a main file "Main Data".
I what to be able to open each file copy from tab "Sauce info" A1:B65, and paste into "Main Data", tab "main" and then create a long list of data.
i need to make a macro that takes workbooks or files and runs them through another macro. i already have the 2nd macro done and it is working perfectly i just need to know how to make the one that finds the other files and runs them all through the macro i already made. My boss said that he will have about 150-200 files to run through this macro.
My issue is that i have a excel spreasheet that contains macros. These macros work on my computer and our VPs computer. We have 4 other computers that were bought recently that have all the same operation systems as mine and the VPs, and save version of excel. I can not figure out why it wont work. Following is the code. I think what i have it narrowed down to is the rRange.copy. I dont think its copying on the 4 computers that it dont work on.
' this section prompts the user to select a range
Sheets("2008 drivers sch").Select
Dim rRange As Range
On Error Resume Next Application.DisplayAlerts = False Set rRange = Application.InputBox(Prompt:= _
#1 So what I want to do is copy multiple rows from a table into another table, but only info from column a,b and c of that row into the other workbook's table. So I need to search for the number that is in E1 of workbook#1 and pull the rows that have that number from anywhere down column E of workbook#2. But I only want the info from cells a,b and c of the rows to transfer over.
#2 Also how to pull that off on all the sheets 1,2,3,4,5,6,7,8,9,10,11 and twelve of workbook#2's column E's into one list in workbook#1.
#3 How to put a button for the macro so if I change the value in E1 I can just hit it to repopulate the workbook#1 with a new list.
#4 How to pull from page 1-12 of workbook#2 but also a workbook#3 as well.
I have the following macro which copies data from one spreadsheet to another spreadsheet. The 2 files are specifically named in the database so they must have those specific file names in order for the macro to work.
Is there a way to set up this macro so that it automatically copies the data in the file that is active at the time (File1 in the attached code) to File2? File2 will always be the same file name, so that part of the macro is fine as it is. The active spreadsheet will always be the same format (so the Source Cells will work) but it may have a different file name each time.
I have 2 tabs (tab 1 is "Data", tab 2 is "Compare")
Data tab is filled with results from tests I do in a lab, each test has its own row, each 'test subject' has its own column.
In the second tab I want to have the ability to pick from a drop down list one of the other columns from the first tab.
So I have 2 columns (D and F) in tab 2 with drop down lists that I have populated with the names of the test subjects (using data validation grabbing the top row in tab 1).
I have formulas set up in Column E of tab 2 for the actual comparison.. What I'd like to do is when I select a test subject (for example SubjectA), from the drop down list in $D$1.. I want to populate $D$3:$D$155 with rows 3-155 of the matching column in tab 1 (so if for example SubjectA is in column X, it would copy from tab 1 X3:X155 to tab 2 D3:D155.
So so far I have the validation part done with the drop down list.. and I have the following VB code for tab 2.
What I want to do is for a macro to run and for that macro to copy data and place it in a specific place. For example i want it to take the the 20 from "Village Headquarters (Level 20)". Another time when I run the script the 20 might be a 30. I there a way to do this? To define a place to take the data from within a cell.
My other question is, is there a way to have a macro automatically paste data one row down from the time it was run last?
I would like to copy a range of cells with a marcro, for example copying range C3:C15 over to D3:D15 and when I run the macro again I want range D3:D15 to copy to E3:E15 and from there to copy E3:E15 to F3:F15. I want to keep that going to the next and the next with the same macro. But it just keeps copying the the original range which I recorded in the macro, but I want it to keep going. If somebody can help me with that, I would sure appreciate hearing from you.
I have 2 worksheets. The first worksheet contaions raw data. On the second worksheet I am pasting certain data from the first worksheet. Everything copies except the data in column BI. This column has blanks as well as numbers. I need the column copied as is. The range should equal the number of entries in column A. Why am I getting the error, and Is there an easier way than what I'm using?
Is there any code that can be written so when a person selects a tab to be moved to a new workbook, the macro code in the existing workbook would be copied to the new sheet? I'd also like to use a button that the user could click on for the macro.
I am creating a macro for a monthly report of inventory. When I filter out items and the copy and paste them to another sheet, how do I tell the macro to paste it in the next available cell rather than say A20? Because the report has a different number of items and filter results from month to month.
I am creating an order form and after a user makes an order I want the data the be copied accross to another table (on the same sheet) - like an archive. I would like to create a macro that does the function. However, what I have thought of it that if I record a macro that cuts and pastes e.g. cells A2 and B2 to cells H2 and I2, the first time an order comes through it will be fine however, if the macro is run again it will keep over-writing the existing data in the archive section.
So, is it possible to construct a macro that will copy accross the data but each time it is run won't over-write what is in the cells. Like using an IF statement in the macro (if cells H2 contains data, then move to next avalible cell).
I need to able to copy certain parts of cells and paste it somewhere else. The data within the cell is presented like this City A/City B/City C. With an '/' seperating each. How can I copy just one part of that string using a macro(city a), and then keep track of it so that the next time I use a macro on that cell it copies the next part of the string(city b). I'll always copy the first City first so deleting it after it is a copied is an option but I dont even know how to do that.