I got a table which is used to calculate the financial rent ability of certain projects.
The years are in the columns, so for every year there is an entry for revenues, costs, etc.
The lifetime of the projects differs (sometimes 10 years, 20 years, etc.). So if it is chosen that the lifetime is 10 years, I would like the table to only show (and also use) only the first 10 columns (for 20 years the first 20 columns), etc.Is this possible and if so how?
I have an excel 2003 sheet that collects data from Infopath forms. The forms are to record students who have broken school rules, when, where, repercussions etc. One column shows their class and there is a separate column for each rule broken.
I want to create another sheet to show each class down the rows and the columns to show each school rule. Therefore, each cell would show the number of each particular rule broken for each particular class. I have tried to do countif and sumproduct (if on sheet 1, column B the class is KA and on sheet 1, column M, the rule is bullying = how many times this has occurred).
I attach a file for you to more easily understand my problem. I have a big table with information, then I would like to summarize this, if all fields for certain "Type" (see file) is blank, then I would like to use another value that I keep as a separate row in the summarize table. But I also need to have it to work if zeros are put in, I need to show that value, that's my biggest problem right now when using sumif forumla.
I have to divide two columns. Sometimes there is a zero in one of the columns. Now, I realize that nothing can be divided by zero, but isn't there a way to show a zero instead of the #ref symbol???
I have a table with row headers (in column A) and column headers (in Row 1). Throughout the table there are 1's and blanks depending if the column is applicable to a particular row or not.
I want to write a VBA macro to do the following:
1. Do a Vlookup of column A for a particular user input text string. 2. Only show the row that matches the text string. 3. Only show the columns where there is a 1 associated with the selected row.
Then once that is done I need a separate macro to return the sheet to show all the rows and columns.
For input I have 2 columns: A---B 1---5 3---4 ----- 2---- I need for output column C: C 1 2 3 4 5 It's possible to do that using one or more function ?
I'm looking at trying to view 1 large keyword phrase list of about 40,000 phrases to another large list.
All I want is a macro, I can assign a button to. Click it and in a new sheet it shows only the rows of data that are different.
I have tried googling it.
I found 1 that looked very good (Not that I really know anything about coding, but I couldnt get it to work.
I'm using excel 2007. As a note the link was here. [url]
I might as well post the code,, but I just couldn't get it to work, shame, because it sounds like it could be what I was after, I'll post it now, but if anyone can help me with this that would be great
Sub CompareWorksheetRanges(rng1 As Range, rng2 As Range) Dim r As Long, c As Integer Dim lr1 As Long, lr2 As Long, lc1 As Integer, lc2 As Integer Dim maxR As Long, maxC As Integer, cf1 As String, cf2 As String Dim rptWB As Workbook, DiffCount As Long If rng1 Is Nothing Or rng2 Is Nothing Then Exit Sub If rng1.Areas.Count > 1 Or rng2.Areas.Count > 1 Then MsgBox "Can't compare multiple selections!", _ vbExclamation, "Compare Worksheet Ranges" Exit Sub
I saw a great code which compared the values in two columns A and B, data such as A123 and then shows, in another column ie C , things in A and not in B and in another column ie D things in B and not in A.
I have a spreadsheet which has a number of columns populated with a day number and below each day number there are some numbers. What I would like to do is to compare the values for Day1 with Day2, Day 2 with Day 3 etc. Is there a smart way to do this using VBA? I am enclosing an example to show what I would like the macro to do.
1. W1 has data in Column A, while W2 has none in that column (except for the header row of course). 2. W1 has rows that W2 does not have, and vice-versa.
I need code that will compare three columns in these two sheets. If the data in these three columns for a particular row match between the two worksheets, then for that row, I need the macro to copy the column A cell in W1 to the corresponding column A cell in W2. Finally, I would like an 'x' be placed into a W1 column if a match was found for that row.
The two sheets do not have the same number of rows, but the data being compared in the three columns should combine to form a unique row match between the two worksheets.
I have a simple macro that I have been using to hide columns in a very large spreadsheet. Essentially, the user has access to buttons that allow him to choose between a variety of the most commonly used views. For some reason, when I add columns and adjust the code to hide/reveal these columns, I get:
"Run-time error '1004' - Unable to set the Hidden property of the range class"
with the Debugger highlighting the code for "BO:DC". This problem occurs for several of the similar buttons, including toggle buttons, that hide/reveal columns. I am aware that custom views can be created in the drop-down menu, but I wanted to keep these buttons on the sheet as a quick means of moving from view to view and toggling columns between hidden and revealed.
I have a userform labels role_selection with 5 checkboxes. Each checkbox with the caption labels as follow: Students, Teachers, Below Average, Customer, and Friend.
In addition, a 3 worksheets each labels as follow: Main page, General, and Final.
The General worksheet has the same name as the 5 checkboxes (Students, Teachers, Below Average, Customer, and Friend).
My question is how can i write a program to determine which checkbox is selected and compare the selected checkbox caption to the names that already existed in the general sheet. If the name exists show that name and hide the rest ...
I have this tab that won't show the marks when I group the columns or rows.
I know it is grouped becuase if you copy the data to the blank tab the marks appear fine. Copying the data is an easy work around but I would really like to know the root cause of this. The issue was only with this tab. I used to have a ton of other tabs and they grouped fine.
I'm interested in comparing the 2 columns of data as attached in the SampleData file, for eg. First customer bought 5 items and customer 2 bought 3 items. I'd like to show the difference which customer 1 bought and customer 2 did not buy. Will need to use that via VBA And also for loop if possible!
Basically, when you select Fred and 4, I want to to display 601, 799, 1023, and 1547 in the columns to the left of where you do the selection. (which is not in the same place as that table at the top of this question.
I have a couple of functions running in my workbook, and for no reason that I can see, when one of them runs during a simple macro I use to show/hide some columns, the worksheet vanishes. Is there a way to stop all functions running while I show/hide columns?
I have 3 columns (Name, Pass Date, Fail Date) Each name will only have 1 date in either column B or C.
I want a formula that will say "if there is a date in the pass column (B) then this name is a pass, if there is a date in the Fail column (C) then this name is a Fail"
I have a spreadsheet that has a userform attached to it with text fields that enter additional data regarding each record. The userform takes these additional 5 fields and inserts them back into the spreadsheet, the final information to be exported back into Access. ( There are of course other ways to do this, but this is how my supervisor wants it done!)
My problem is that now that I can scroll through the spreadsheet without closing the userform, the userform doesnt show the current row's information as I scroll or change rows on the spreadsheet. It will only show the information that was in the row that it was on before i switched back to spreadsheet.
I have a spreadsheet with four columns of data for every month (i.e. January has a Prior Year, Budget, Outlook, and Actual column). I have been trying to come up with a macro or form that will allow me to customize which columns I would like to see and hide the rest. For example, if I chose to see the Budget and Actual columns, it would hide the Prior Year and Outlook columns for each month.
I have three columns that each have a drop down of text options; column A has three options, column B has three options and column C has two options. I want to have a fourth column that will show a text value dependent on the combination of the three columns.
It ends up being 18 variations so my IF formula just won't compute.
This is basically the format I have and works for a few values then just chucks up an error when I extend it to all 18 variations:
IF(AND(A1="text",B1="text2",C1="text3"),"show this text", IF(AND(B1="other",B1="other2",C1="other3"),"then show this", ) etc etc
Any way I can get this to work for all 18 possible outcomes??
Basically I have a form where the list can expand and contract so there will always be varying row lengths.
What I would like to see is a drop down list that shows a) the actual populated field and b) a description of the field when the drop down list is present.
I believe this can be done with a combo box however that would be a lot of work.
I've got a problem with organizing my data. I've performed a study with several participants, each of which does several trials with 8 conditions (1,2,3,4,5,6,7, or 8), with each participant doing a condition more than once. I also have a separate column telling me whether they responded correctly or incorrectly (with a 1 or a 0).
I need to find a way to produce a new column to identify whether they got each condition (of the conditions 1,2,3,4,5,6,7, or 8) correct separately, i.e one column for responses to condition 1, one for condition 2 and so on....
It would also be useful if there was a way that once this is done I could summarize their accuracy of responses to each condition.
I've attached an example of my data. excel problem example.xlsxā€ˇ
I have a very large table and i need to be able to Hide/show specific ranges based on:
Filter +and+ specific cell values in columns
brief example of the table : tablee.png
So... 1. Filter Column "B" (in this case we select "HELPING") 2. Auto hide/show collumns. - IF "C1" = "Required" THAN Show "C:E", IF "C1" ="N/A" , HIDE "C:E" and so on for every column like above.
There are over 80 columns like the "C:E" range. and I only need to show those that are "Required".
List of email addresses in column a List of email addresses in column b
** I would like a formula that will take all the values in column A and compare it to the entire list of entries in column B. Would like it to show in Column C any entries in Column A that ARE NOT in the entire column B.
*Would like it to repeat for entries that are in Column B, but not in Column A and show in D.
*Then would like a count of the differences for each column (that is pretty easy).
It needs to look at the entire list of entries in the column as these will be email addresses. We want to know what is missing from Column A that is not in Column B and what is missing from B that is not in A.
After scouring the entire OzGrid, I have found the following two macros that partly satisfy what I want to achieve. BTW, following two macros are executed on Sheet2 and I want to achieve the following: On Worksheet_Activate, show columns that match the criteria value in Sheet1.D4 (Sheet1.D4 contains a dropdown list with about 6 text values). In addition to that, if Sheet1.D4 value is blank then show all columns. Right now, it successfully shows columns that match the D4 value but does not work if that D4 value is left blank, instead it hides all columns in range (C:CV). So in short, to the first macro, I need to add the criteria if D4 is blank, then keep the sheet intact and don’t hide anything, just show all columns.Once on that sheet after the Worksheet_Activate event has occurred, with the second macro “ToggleColumnsVisibility” following things need to happen. BTW, currently this macro is assigned to a button (from Forms Toolbar).If cell D4 has a value, then the button’s caption should read “Show All” and when that button is pressed, it should show all columns in the range (C:CV), and the button's caption needs to change to “Show Selected”. In “Show Selected” mode, when that button is pressed, it needs to show all the columns that match the D4 value.If cell D4 is left blank, then the button's caption should read "No Action" and when the button is pressed, it should not do anything but just show all columns.
As you will notice in the header, my experience with Excel is very limited, so detailed instructions will be greatly appreciated. I am also hoping that proposed solution uses some of the efficient/effective ways of using loops such as described below (example taken from this website from this link http://www.ozgrid.com/VBA/SpeedingUpVBACode.htm)
Sub TrueOrFalseFaster() Dim bYesNo As Boolean Dim i As Integer bYesNo = (i = 5) MsgBox bYesNo End Sub
Sub ToggleTrueOrFalseFaster() Dim bYesNo As Boolean bYesNo = Not bYesNo MsgBox bYesNo End Sub .........