One Workbook Affects All Workbooks

Nov 20, 2009

I have made a workbook file which is a form. I deleted all tool bars except "Print" and "save as". And I have saved this workbook. When I startup XL again to do other work It brings up my same bar arangement as my form. When I change it back it also changes my form file. How do I keep my form arrangement seperate from the standerd excel set up?

View 13 Replies


ADVERTISEMENT

Code Affects Screen Display!

Mar 2, 2009

I use the following piece of code to Hide/Unhide columns as required by a specific worksheet.

View 4 Replies View Related

Can A Cell Have A Formula That Only Affects Other Cells

May 16, 2009

What I need to happen exactly is this:

If cell BE72 says "Natural", then cell CM11 equals the value in cell BE73.
If cell BE72 says "Deflection", then cell CT11 equals the value in cell BE73.
If cell BE72 says "Dodge", then cell DA11 equals the value in cell BE73.
If cell BE72 says "Insight", then cell DH11 equals the value in cell BE73.
If cell BE72 says "Luck", then cell DO11 equals the value in cell BE73.
If cell BE72 says "Sacred", then cell DV11 equals the value in cell BE73.
If cell BE72 says "Compet.", then cell EC11 equals the value in cell BE73.
But, If nothing is entered in BE72, then I want to be able to type my own values in cells CM11 through EC11 without overwriting any formula.

Since I cannot have a formula in a cell and still type in it without overwriting the formula, I was wondering if it's possible to have another cell (maybe cell A1) that has this formula in it. Can a cell like A1 hold a formula that functions for other cells even though nothing happens in A1? If so, how would I make the above work?

View 9 Replies View Related

Zoom Level Affects Shapes Positioning

Jun 30, 2008

Sub CreateRectangles()
X = 1
Do Until ActiveCell.Offset(X, X).Value = 0
X = X + 1
Loop
variable = Round(-0.026 * (X * X * X) + 0.56 * (X * X) + 24.7 * X + 5, 0)

Set Box = ActiveSheet.Rectangles.Add(ActiveCell.Offset(0, 0).Left, ActiveCell.Offset(0, 0).Top, variable, variable)

With Box
.ShapeRange.Fill.Transparency = 0.3
.Font.Size = 18
.Font.Name = "Trebuchet MS"
.Text = ActiveCell.NoteText

End With

End Sub

View 3 Replies View Related

Calculated Field Deletion Affects All Pivot Tables?

Jul 2, 2014

I have my raw data in one Worksheet and have made multiple pivot tables based off this data. Since I needed to have the same calculated fields in all these Pivot Tables, I used to simply duplicate the pivot table sheet and edit the pivots to create a new table.

Now, I'm trying to create a new pivot table from scratch, by selecting the base data table and going to "Insert Pivot Table". However I see the same Calculated Fields and upon removing, the field is removed from all other Pivot Tables.

View 1 Replies View Related

Web Form Interface- Amount Of Lines Affects Speed

Sep 18, 2006

I built a web form interface which I use to adjust orders on a web-based system our company uses.

The code I have looks at a sheet, checks if the line needs adjusted, makes adjustments as needed, and then clicks a box for lines needing ordered.

Here is the code I use:

Sub Adjustorder()
Application.ScreenUpdating = False
Dim ie As Object
t = ThisWorkbook.Sheets("Adjust").Range("C3").Value 'checks for valid orders to adjust
If t = 0 Then MsgBox ("No Skus to add"): Exit Sub
Set ie = CreateObject("InternetExplorer.Application")
With ie

This all works fine, but the amount of lines can be anywhere from 1 to 11,000. The fewer the amount of lines needed to loop through, the faster it does each line. With 11,000 lines it took nearly 1 second per line. With 200 lines it took 2 seconds for all of them.

View 9 Replies View Related

Macro Copying & Pasting Chart Affects Its Size

Sep 13, 2006

I have a macro that takes a worksheet and copies it to another workbook. It works, but the graph that is contained in the new worksheet ends up a little screwy; for instance, the Plot Area is larger than it should be (height-wise along the screen), and the chart's legend isn't in the exact same place as in the original chart.

ThisWorkbook.Worksheets(tempSheet).Copy After:=wb.ActiveSheet 'before:=ThisWorkbook.Sheets(1)
RenameTemplate

'unlink copy from template
'must unprotect before unlinking. We'll leave it unlocked cuz we don't care.
wb.ActiveSheet.Unprotect
'cells
wb.ActiveSheet.UsedRange.Copy 'ThisWorkbook.Sheets(tempSheet).UsedRange.Copy
wb.ActiveSheet.UsedRange.PasteSpecial Paste:=xlPasteValues ......................

View 3 Replies View Related

Copying Many Workbooks Into One Workbook

Jul 28, 2009

I have many excel files(nearly 500 in total and growing daily) in a folder called "Results Data" on my C drive. The file names are slightly different (serial numbers). Each excel file contains data in Cells A2:E11. I want to be able to copy only the Cells A2, B4, D5 and E10 from each workbook and paste them into a new workbook, each copied workbook on a new row.

I have been trying to change code that I have found on the web but nothing seems to be working,

View 9 Replies View Related

Macro - 10 Workbooks Into 1 Workbook With 10 Sheets

Jan 24, 2014

I'd like to create a macro that will take 10 workbooks and add them to a new work book, but have each workbook as a separate sheet.

So every month from work I get a report file labeled as the current month (JAN_14). Then there about 19 folders in that folders labeled with product names; then in those folders are two excel files (they're all named MSTASCH_QUICKLOOK_1 and MSTASCH_QUICKLOOK). I figure if I can see the macro to combine 10 workbooks I can change it to do less or more workbooks. I had tried a macro that takes the workbooks from one file and puts them into two seperate sheets (although I would love to have the order changed of how they're put into the workbook).

VB:
Sub MergeSheets()
Dim wbDst As Workbook
Dim wbSrc As Workbook

[Code]....

View 4 Replies View Related

Merging XLS Workbooks Into One Master Workbook?

Sep 15, 2014

Is it a good idea to merge xls workbooks in to one master workbook?

I have read online that some say it is ok and nothing will happen and others say it isn't a good idea because macros and formulas will not work right once merge in to one workbook.

So I have many workbooks with 2 - 4 worksheets in them. All have formulas as well as macro's and everything is working fine just as it is. But I would like to have 1 Master workbook with all workbook/worksheets combined in to 1, so that I can stop opening so many workbooks.

View 1 Replies View Related

Merge Workbooks Together Into A Single Workbook

Jul 27, 2009

I have two workbooks that I'd like to merge together into a single workbook. Or, pull the worksheet out of one and insert it into another.

View 2 Replies View Related

Get Data From Several Workbooks In One Master Workbook

Jul 1, 2014

I wish to be able to get data from several workbooks (.xls), and gather all the data in one master workbook.

As I said, I've got a number of workbooks with data I wish to copy and merge into one master worksheet. Each workbook contains a sheet called "MILESTONES" (project) in which I want to pick up data. The data ranges from A5:J88, but I think this can be expanded by the users (more rows). There is no guarantee that the users will enter data in all the columns. Columns A and B occur frequently blank, so the users usually starts entering in information in column C (heading = description).

The Master workbook contains of exactly the same headings, except that the columns has been expanded by 1. Column A1 has the heading "Workpack" which is the name of the workbook the information has been gathered from (description is in column D1). This name can be found in a sheet called "REPORT" in all of the workbooks, and I want this to be copied over, row by row so it matches the data. I don't know if it can cause any trouble, but the names are merged through C to J in row 12 in all of the workbooks.

The workbooks (or workpacks) and the master workbook (summary) are placed in the same folder. Let's say C:Project. The workbooks also changes names frequently (each month). Lastly, if there is a way to automatically update the master workbook every time it is opened.

View 5 Replies View Related

Close All Workbooks Except For The Main Workbook

Jan 5, 2009

Is there anyway to change the following code so that it will save and close all workbooks except the one that has this code?

View 3 Replies View Related

Consolidation Of Workbooks Into Single Workbook

Oct 12, 2009

I'm looking to run a VBA script that will take all excel spreadsheets within a specified directory and copy a named range "Data" from each worksheet, and place it into a consolidated worksheet.

"Data" array is tentatively B2:B16. However, these files are being sent to many resources to consolidate, therefore the range can change.

Subsequent records added via Column, not by row. So worksheet's 1 data would be A2:A16, and worksheet's 2 data would be B2:A16.

Names of the worksheets are variable, but all worksheets within a given directory will need to put imported.

My VBA skill is about as developed as a 2 year old's language skills. Could anyone assist me?

View 10 Replies View Related

Collate Four Workbooks Into Single Workbook

Oct 17, 2011

Macro to collate four workbooks into single workbook.

Sheets in workbooks also to be copied. The sheet 1 of the 4 workbooks should be combined into the sheet 1 of the new workbook. Sheet 2 of the 4 workbooks should be combined into the sheet 2 of the new workbook, and so on.

[URL] ..........

View 2 Replies View Related

Copy From Multiple Workbooks To Another Workbook?

Nov 19, 2012

I have a database from which I extract 5 different excel files. For arguments sake, they are called File 1, File 2 etc. Each of these workbooks will have a sheet called 'Raw Data'. These will all be save in the one directory, C:Data, for example.

I am after a macro that can copy all the data from each of the workbooks, on the sheets called 'Raw Data, however the data in each of the workbooks will vary in length and width.

The workbook which I want them copied to is called "Template" and I would like the copied data onto separate sheets in this file. If possible I would like them copied to already named sheets, for example in the "Template" file, sheets may be called "Raw Data1", "Raw Data2" etc.

View 6 Replies View Related

Combine Multiple Workbooks Into One Workbook

May 31, 2013

I have this master file with a list of workbook names in column A on a tab called, conveniently, List. I have saved the master file in the same folder as a number of workbooks where their names match the names on the List.

What I want to do is open the files on the List and copy and move the worksheets to a new workboook. The catch for this is the following (I will use an example):

1. I have 2 workbooks called DS-100 Medicine Admin and DS-101 Medicine Wards
2. I want to take the worksheets from DS-100 and add them in a new workbook
3. Then I want to take the worksheets from DS-101 and add them to the same workbook but AFTER the DS-100 worksheets that were added in step 2
4. Then save this workbook to a folder within the original folder where the files are saved

I have the below code thus far, which opens the DS-100 workbook and copies and moves the worksheets to a new workbook. It doesn't open the DS-101 workbook though. It also saves the new workbook in My Documents rather then the SavePath.

Sub CombineMedicine()
Dim Path As String 'string variable to hold path to look through
Dim FileName As String 'temporary file name variable
Dim Master As Workbook 'this workbook
Dim rng As Range

[Code] ...........

View 1 Replies View Related

Transfer Data From One Workbook To Several Workbooks

Jun 16, 2013

I have several hundred workbooks an am trying to write a macro to transfer data from another workbook "_TABLES.xlsm" to each of them. By using 'Record Macro' I have so far come up with -

Code:
Windows("_TABLES.xlsm").Activate
Columns("B:L").Select
Selection.Copy
Windows("12-01-01 Results.xlsm").Activate
Sheets("ToDBase").Select
Range("B1").Select
ActiveSheet.Paste

Where "12-01-01 Results.xlsm" is the receiving book. My question is - what do I call a generic sheet so as I may drop the macro in all the other workbooks not labelled "12-01-01 Results.xlsm".

View 3 Replies View Related

Join 6 Workbooks Together To Make One 7th Workbook

Jun 27, 2013

How to do this with a macro but I want to join 6 workbooks together too make 1. Master sheet (7th copy). Below are the points of interest and a couple of questions.

1- My six books are all identical in cols.
2- The six books all have in col A my own ID number, no ID number is the same in any worksheet.
3- If I can get all 6 books together then the ID will start at #1 and finish approx at 225,000, in accending order.
4- All books have only 2 worksheets inside, Sheet1 and Sheet2 .
5- I don't want to delete or loose any data in the 6 books already made. Just make a 7th copy of the 6 .
6- The 6 w/books are called
6A- Each w/book contains approx 40,000 rows except last , approx 22,000

UPTODATE STAKESWTD SECT 1
UPTODATE STAKESWTD SECT 2
UPTODATE STAKESWTD SECT 3
UPTODATE STAKESWTD SECT 4
UPTODATE STAKESWTD SECT 5
UPTODATE STAKESWTD SECT 6

7- There are no functions in any of the w/books, just other macros which I want in the master copy.
8- Can the 7th copy be called UPTODATE STAKESWTD MASTER

View 2 Replies View Related

Merge Workbooks To Master Workbook

Sep 24, 2013

at the moment I'm trying to consolidate four Workbooks to a Master Workbook.

The four Workbooks I want to merge have the same table structure but except the "Project Number" they have almost different data in their columns.

What I want to do is creating a Master Workbook in which all the Projects are listed once with the information of all four Lists.

While consolidating the data should be checked whether it is already in the Master Workbook or not:

If yes the Macro should copy the to adding data in the existing Project row and there in the correct column.

If not the Macro should create a new row for the Project.

View 3 Replies View Related

Copy From Multiple Workbooks Into One New Workbook

Jun 3, 2014

I found a great code for copying worksheets from multiple workbooks (up to 2000 workbooks) into one new workbook. It works perfectly for 99% of the copying/merging that i do. The only issue with the code is that it only copies from the active sheet in the other workbooks. I need it to copy from a specific sheet ("Travel") in all of the workbooks that i select. I've tried many ways to edit the code to change the activesheet to "Travel" but i cannot get it to work.

Option Explicit Sub CombineDataFiles() Dim DataBook As Workbook, OutBook As Workbook Dim DataSheet As Worksheet, OutSheet As Worksheet Dim TargetFiles As FileDialog Dim MaxNumberFiles As Long, FileIdx As Long, _ LastDataRow As Long, LastDataCol As Long,

[Code]....

View 5 Replies View Related

VBA Copy Workbook To Mulitple Workbooks

Apr 25, 2007

I am attempting to create a macro that does the following. I need to copy the active workbook to 25 new or existing workbooks without showing "save as" etc. These workbooks will reside in the same directory as the active wb. Problem is, I have multiple directories that I will need to do the same action.

C:ClientClientNameExample1.xls (only has sheet1)
---This will be the master which needs to be copied to 25 more times like below.

C:ClientClientNameExample2.xls
C:ClientClientNameExample3.xls
C:ClientClientNameExample4.xls
C:ClientClientNameExample5.xls
etc...

View 9 Replies View Related

Copy Multiple Workbooks Into One Workbook

Jul 4, 2008

I need to copy multiple workbooks of similar format into one new workbook called "ZZZ.xls". I have developed the below code but I got an error :
Run-time error '1004':
Paste method of worksheet class failed.

Sub create_intransit_stock_FOR_RCP()

Dim Wk As Workbook
Dim FileToOpen As Variant, i, j, k As Integer
Dim NewWBName As String, NewWBName1 As Workbook
Dim OutFileName As String

OutFileName = "C:My_DataZZ.xls"

'On Error Resume Next

FileToOpen = Application.GetOpenFilename(FileFilter:="Microsoft excel files (*.xls), *.xls", Title:="Press CTRL Key to Select Multiple Files", MultiSelect:=True)

If IsArray(FileToOpen) Then
For i = LBound(FileToOpen) To UBound(FileToOpen)..............

View 9 Replies View Related

Workbooks.Open Does Not Activate The Workbook

Nov 5, 2008

I have a workbook containing macros that opens a second one (no macros) and does some 'data mining'.

The following VBA is used for that (I use this code on dozen of files and it has always worked, except here):

Set WshShell = CreateObject("WScript.Shell")
ChDir (WshShell.SpecialFolders("MyDocuments"))
BladNaam = Application.GetOpenFilename("Excel File, *.xls", , "Excel")
Workbooks.Open FileName:=BladNaam
TabNaam = ActiveSheet.Name

The problem is that most of the time the newly opened workbook is NOT activated (i.e put on top) and thus the rest of the code is executed on the wrong workbook...

If I put in a Msgbox(ActiveWorkbook.Name) 9 out of 10 times the active workbook is the initial one and not the one that was opened by the code.

tried replacing Active.Workbook with wb (dim wb as workbook).
tried to wait-a-few-seconds in between code
tried renaming

View 9 Replies View Related

Copy From Many Workbooks To Master Workbook

Aug 18, 2006

I have 600+ variations of the same workbook. Contained within each workbook is a worksheet, from which I need to copy and paste a range of cells into one "master" workbook. For example, in workbook 1 I need to copy rows 2:5 and paste that into the master workbook in cells 2:5. Then I need to open workbook 2, copy rows 2:5 and paste them into the master workbook starting at row 6. I have fumbled my way through everything except the pasting part into the Master workbook.

View 9 Replies View Related

Copying All Workbooks In A Folder Into 1 Workbook

Feb 27, 2007

1. I have a large number of Test Suites that are large documents with 1 (visible) sheet w/ test cases, and 1 (hidden) sheet w/ validations. Test Suite is saved with a unique name (that follows a naming convention we've set up on this project: <Project>_<Test Suite Category>_<Location in Software>_< date>.xls

2. I need to create a master document in which i can run a macro that will copy each "test suite" sheet from each of these documents, insert it into the master doc, and sort the sheets by name. then it needs to present the data from all of the sheets on the main page of the doc, and break down the results by Test Suite Category, and Location.

Is this possible?

Can I create a macro that will import sheets from (potentially) hundreds of different workbooks, and then sort them appropriately?

I've been looking all over the place, and while i've seen macros that can import specific data, rows, or columns, i havn't quite seen what i'm looking for.

View 9 Replies View Related

Split Workbook Into Multiple Workbooks

May 31, 2007

I'm attempting to take a Workbook that contains 1000 Worksheets and split it into 2 separate WB's of 500 WS's each ... basically half it. This could also apply to a WB that contains less than 1000 WS's, but it is highly unlikely it will ever contain more than 1000 WS's.

I'd like each new WB created to be saved in the original path with the original filename followed by a "1", "2", "3" or "a", "b", "c", etc. For example:
Original Filename = ImpactAnalysis.xls
New Filename 1 = ImpactAnalysis (1).xls or ImpactAnalysis (a).xls
New Filename 2 = ImpactAnalysis (2).xls or ImpactAnalysis (b).xls

I've located 2 modules in the forum that are a good start, but each creates a separate WB for each WS, which is a bit cumbersome with up to 1000 WS's in the original WB.

Sub splittest()
Dim sht As Worksheet
Dim w As Worksheet
Application. ScreenUpdating = False
Application.DisplayAlerts = False
For Each sht In Worksheets
Set neww = Workbooks.Add
sht.Copy neww.Worksheets(1)
With neww .....................

View 9 Replies View Related

Data From Multiple Workbooks Into 1 Workbook

Jun 14, 2007

I have 2 Excel templates using lookups to create customer quotations. When complete a macro is run which strips out formulas and links to data.

I would like to record certain data from the finished workbook in another workbook on the server e.g. quote number, date, customer, total value, follow up date.

Is it possible to include another macro that records data in certain named cells to a separate workbook when the file is saved?

View 9 Replies View Related

Consolidate Multiple Workbooks Into The Master Workbook?

Jun 12, 2013

how to consolidate multiple workbooks into the master workbook? I need to consolidate 12 workbooks into the master workbook every month. The subsidiaries will report me their figures monthly. Hereby attached one of the subsi, "B Co" reporting package, and the master copy "XYZ Holding Co" how it look like. Hence, may I know how to write a macro so that it will auto update monthly when the subsidiaries return me their reporting package, so that I can auto update in my master copy for tab BS and tab PL.

View 6 Replies View Related

Create Master Workbook From Multiple Workbooks

Jul 3, 2013

I need to consolidate a lot of information from multiple workbooks all the workbooks are located in a folder, i am not bothered about running each one separately or a group at a time, each work book has ten sheets with each sheet in the workbook being different, it needs to add to the next blank row on each sheet.

View 1 Replies View Related







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