I've tried using the worksheetfunction.sumif route and couldn't seem to get the syntax correct. I'd prefer the worksheetfunction route, as I don't need the formula stored, but it would be great to have both of these pieces of code for reference online - I scoured Google, and the examples I found were pretty weak.
I've recorded the macro (hence the R1C1 references in the second example) and had it work perfectly, but when I replaced row references with my variables, it went back to displaying "TRUE." I'm including all the code here.
Variables:
expr = 3 to 38 (For loop)
startrow = the starting row for the reference data
endrow = the ending row for the reference data
thresh = minimum threshold (a number)
I want to perform a SUMIF if more than 1 condition is true. I can do a regular SUMIF if, for example, values in column A is > than 10,000, then SUM associated values in column F.
However, what if I want a SUMIF if values in column A is > 10,000, values in column B = “Yankees”, then SUM associated values in column F.
I have a formula that I'm trying to utilize VLookup to determine a specific bonus. The issue I'm having is when looking for the closes match, it is returning the value below where it should because it's rounding down. For example, the string I have reads:
=VLOOKUP(S5,'Rep Daily'!A1:B61,2,TRUE)
The value it's defining is 17.7485, so it's returning the bonus for 17.5 instead of 17.75. Even when I use the =Roundup function, it's showing 17.75 in the cell but the actual value of the cell is 17.7485 so VLookup is returning the lower of the two values.
I want to run a macro if the result of an IF function is true.
E.g. cell J55 contains =IF(H55>I55,"Goodbye","")
H55 contains =NOW()
I55 contains =DATE(2012,12,31)
Now by changing the dates etc. it prints Goodbye.... simple enough, but what I want is for it to run a macro that selects a range from the previous year's figures and simply changes the fill colour on the range. The macro for this also works fine.
I have a worksheet called "Raw Data" where in columns J, I and G contain values. I would like to write a formula whereby if all 3 conditions are met, it will count the number of values found in column C.
I've tried to write an IF statement but it just returns FALSE, despite the result being true. Need the right combination of IF/AND statements that would do this?
=IF(AND('Raw Data'!$J:$J="Maintenance",'Raw Data'!$I:$I="Open",'Raw Data'!$G:$G="1-2008"),COUNT('Raw Data'!$C:$C)). I've tried to attach the workbook, but there's a problem with uploading attachments I think. Sorry if my explanation is unclear.
I am new in Excel VBA and im trying to find a way to get back a result "True" or "False" when I have password, wich must consist of 6 letter, one upper case letter and a number must be in it. When this word consist of 6 letters and has a uppercase letter and number the result is True and this will be written into the cell next to the cell where the password is.
I am trying to create a formula to count the number of time the word "NEW" appears in one column, provided the result of another column gives a certain answer. Sample of my problem and question in detail on attached.
I've got a formula that has numerous nested IF statement and am trying to get the true result to be the first of a given month of the current year. Here's my formula:
Everything works, save that the cell becomes 1/1 with no year at all. I've messed around a bit with TEXT and various DATE/MONTH/YEAR functions on this one, but can't seem to get it correct.
The value in A1 can range from 0-10. If the value is 0 I need the result to be 0, if the value is 1-10 I need the result to be the number multiplied by 613.35 plus 29.35 for example =sum(1*613.35)+29.35 or =sum(2*613.5)+29.35.
i have this function that poulates data from a userform into a sheet.
For lLoop = 1 To MAWBNoVar With Range("B" & Rows.Count).End(xlUp) .Offset(1, 0) = Controls("txtMAWB" & lLoop) .Offset(1, 1) = Left(Controls("cbDestination" & lLoop), 3) .Offset(1, 2) = Controls("txtGW" & lLoop) .Offset(1, 3) = Controls("txtCBM" & lLoop) .Offset(1, 4) = "= ROUND(E" & Y & "*167,0)" .Offset(1, 5) = "=IF(D" & Y & ">F" & Y & ",D" & Y & ",F" & Y & ")" .Offset(1, 6) = "=IF(F" & Y & ">D" & Y & ",G" & Y & "-D" & Y & ",G" & Y & "-F" & Y & ")" Y = Y + 1 End With Next lLoop
My problem is that the data being entered into the sheet for the lines highlighted in red is going in as text, and not true numerics, so that the subsequent formulae are not working correctly.
I'm trying to sum the values in a column if 2 different conditions (in 2 other columns) are true (so I'm evaluating 3 columns total).
For example, if I had a list of the prices of all the cars available at a dealership (each car listed on a different row), and I wanted to find the total cost of all toyota celicas listed, how would I do this?
Basically, I'm trying to create a formula that says "if the value in the make column = toyota AND the value in the model column = celica, then sum the related values in the price column."
Is there a simple solution, by changing something in the button properties? My current code below allows data from a userform to goto specific sheets and cells. Currently my option button named winbutton if true will display "true" in cell. i need it to be numerical value "1".
I am trying to write a formula using If statement to output the result "True".
I have 4 columns (P3, T3, AD3, AK3) that store a value of either "Yes" or "No", I want to check the column if they are equal to "Yes". I have written a formula but it only works for 1 column at the minute, i not sure how to add the other columns into the formula:
I have a column that says either TRUE or FALSE this is dependent on what number i input into another cell, so if i input 8, TRUE shows on every 8th row,
I want the cells that say TRUE to also have a sequential number next to it in the column beside it.
Formula i have: =MOD(ROW(S2)-1,nth_No.)=0
So for example, every 3rd row is TRUE, i am wanting a sequential number beside it:
I have an Excel workbook which has 10 rows of numbers with a min of 20 and max of 30. The random number lies in column B and this will be tested to see if it lies between the min and max. I need to loop this 10 time over
I first started out declaring the 3 variables and assigning values to each variable. It works if I assign a value of 22 for Number but I want VBA to see the Number and make a decision (True or False) if that number lies within the range of 20 to 30.
Should I name the Number variable as a variable because its value will change depending on if it matches the conditions? Also would a case be easier? Between.xlsx
I'm trying to count the number of occurrences where two conditions in a table are true.
I have a table that has two columns for ratings; impact and probability. Each can be scored 1-5 This creates a matrix table of possible scores from 1 - 25 (image attached)
I want to COUNT the number of items in each of the boxes (not the total score). For example, how many are Impact 5 and Probability 5 (25 total); how many are Impact 4 and Probability 2 (8 total), and so on. Basically a count of the each of the intersections in the matrix.
Something like "Countif Impact is 5 AND Probability is 5"
Is it possible to count something once, checking for multiple conditions?
I am using a spreadsheet to determine if students are meeting Growth Targets between a pre test and post test.
Here is my formula
=If(D8>=C8,"yes","no")
D8 is the Growth Target and C8 is the Post test Score.
After doing this, I need to calculate the percentage of Yes results. This year it will be easy, as it only applies to 25 students. Count the yes's and multiply by 4. Next year, it will apply to number in the neighborhood of 150 students.
I have a list of items that I am preparing to upload to an access database. The list is quite lengthy and has required a lot of manual corrections to get it prepared for upload. It also has several columns that are not needed in the access database, but that I used to make sure that all of my data was ready. What I'd like to do is create a new table that will have the same structure as the table in my access database and upload the portion of data that I have ready now so that I can do some further development using actual data. In order to do this I need to extract the ID Numbers (column B values) of the records that are marked "True" in the "Ready" column (column G Values) and deposit them in the new table. I only want to copy over the ID Numbers as the additional fields will be populated with match / index lookups from a third table that I have on another worksheet.
I have two columns with values. Then I have a third column with one letter A or B.
I'm not used to excel, but I've tried my way with COUNTIFS and I'm pretty sure it's the way to go, but I'm lost in the syntax.
I want to count the number of times the values in the first column is larger than the values in the second column, if the letter is A. And then flip the ">" sign and count that and hopefully the first number is higher.
I have two data columns: the first is a list of the last 100 calendar dates, and the second is an ON/OFF (or 1/0 if you prefer) value corresponding to each date. If the last value in the second column list is ON, I want to find how many continuous days the value has been ON for. If the last value in the second column is OFF, I want it to return a zero. Note that in the 100 day span of data, the value may switch between ON and OFF several times, but I only want the continuous, uninterrupted ON days at the end of the date range.
I'm trying to make a formula but are failing. This is the data:
Cells: a1= ant-gel a2= ant - gel a3 = size 1 - 6 a4 = size 1-6 a5 = book - 5 a6 = book-5 a7 = good book
I want a formula that displays "True" if cell contains a "-" symbol AND the dash symbol is surround on both sides by a number (a space can go between dash and number)
I want the results to go in column B
For example, if a1 contains a dash and dashes are surrounded on both sides by a number, then "TRUE", otherwise "FALSE.
I have a worksheet where I have around 300 rows, each with 7 columns. What I want to do is add a checkbox to each column. I plan on setting non-applicable checkboxes to mixed status and locking the worksheet. I will unlock applicable checkboxes and sumif or countif their value according to row-based scoring, for example, each checked checkbox represents a value of 3. I do not know VBA and have chose to use the form control checkboxes rather than ActiveX.
I believe that a formula for this would be something like: =SUMIF(B1:B3,True,"3") or =COUNTIF($B$1:$B$3,True)*3
I am wondering firstly if I have that right and secondly if there is a way to stop my checkboxes from displaying labels. Currently, if I click on one it displays True behind the active checkbox. If I uncheck it, it displays False.