Creating Loop With Small Formula?
Mar 13, 2014
I am trying to get the following thing started but my loop doesn't succeed. I've got 3 columns. I need to place a formula in column C if A is empty.
Example:
A2 contains data so do nothing.
A3 is empty do: C3=B3+B4.
A4 contains data so do nothing.
A5 contains data so do nothing.
A6 contains data so do nothing.
A7 is empty do: C7=B7+B8.
this is what I've got so far:
[Code] ..........
View 4 Replies
ADVERTISEMENT
Dec 10, 2008
I have the formula (found in cell "C2") on the Report sheet. I need to perform a function, but I cannot get it to work on the sheet I need to pull information from. The sheet RecapWk12 has a small section pasted (with some cells edited for obvious reasons) from the actual workbook. I can get the formula in Report cell (A10) to work on pulling information from sheet2. You can see I am getting (#REF!) in cell C2.
View 3 Replies
View Related
Dec 6, 2006
I wondered if there is a possibility to make this
Range("L3").FormulaR1C1 = "=SMALL(R[-1]C[-11]:RC[-11],1)"
Range("L4").FormulaR1C1 = "=LARGE(R[-2]C[-11]:R[-1]C[-11],1)"
more simple so i can get the range for my small and large formula's variable? What i try to reach here is:
Range("L3") = smallest date In Range("A2", Range("A" & Rows.Count).End(xlUp))
Range("L4") = largest date In Range("A2", Range("A" & Rows.Count).End(xlUp))
View 6 Replies
View Related
Jul 28, 2009
Ok, I want to use a dynamic range in my Vlookup formula.
I want to use this formula: ....
View 11 Replies
View Related
Jul 21, 2006
I need to complete my business price list. Basically it's an XL sheet with all my suppliers products listed, there price, my margins, and my retail price and bulk price. Currently I'm fiddling with my margins and the best way to implement a formula to reflect these margins. Rather than do it manually, is there anyway I can create a forumla for different gross margins to be set for a certain range of the suppliers goods. For example, any product I buy thats costs me between $0-$20 has a set margin of 1.44 (44%), or a product who's price ranges from $100-$200 has a set margin of 1.26 (26%) etc. This would cut out then need for me to manually check suppliers prices and change to margin accordingly, thus saving me much time.
View 7 Replies
View Related
Sep 15, 2014
I have one data tab which constantly changes. (adding more products and corresponding volume/prices) For the lookup tab, I want to look up one value and return multiple values.
I have figured out an index array formula but it just calculates so slowly. My live file is about 8MB now. When I apply my formula, it takes forever to save.
View 7 Replies
View Related
Feb 4, 2013
I'm trying to finish writing the last portion of a macro created to automate my data analysis project for my research but I'm having trouble writing the last For Loop of the code. I have a target cell B25 which states a given temperature of my reaction. Once a value is entered in B25, 5 activity coefficients are calculated and displayed in cells B31,35,39,43, and 47 which I would then like to copy and paste in cells J31-J35.
However, I'd like to calculate the activity coefficients for a range of temperatures which are listed in cells J30-W30. Thus, I need to create a For loop which copies the value from J30 into B25, copies the values from B31,35,39,43, and 47 to J31-J35 and then moves to the next column replaces the value of B25 with K30 and repeats the same process until all the columns are filled.
View 2 Replies
View Related
Dec 15, 2011
I've got a code that stores a variable and then searches for that variable in a different file. When it finds the answer it it jumps over and up and highlights a different cell. The problem now is that I want it to keep searching past where the first result was and repeat this process down the entire column. Here's what I have so far:
Code:
Sub Find()
'
' Find Macro
' Finds a specific key word or phrase from the search box and codes the matches green.
MsgBox "This may take a moment, please be patient."
' This next line establishes the fact that the function will use a variable.
Dim FindClass As String
On Error GoTo ErrorCatch
[code]....
View 3 Replies
View Related
Nov 2, 2011
i am trying to write a macro to loop through a column of data, creating a named range each time it encounters a certain string. so, it inititially finds the first instance of the string, then finds the next instance, offsets one row back and then names that as the first named range. how do i get it to actually loop through the column until the end of the data?
I can get the first range named but can't figure how to get a loop into my macro to repaeat the process.
Code:
Sub x()
Dim rngTemp As Range
Dim rngFind As Range
Dim rngFirst As Range
Dim rngLast As Range
Dim nom As Range
Dim strFirstAddress As String
[code].....
View 2 Replies
View Related
Dec 7, 2006
I have a problem with the code below. When i place the statement "MsgBox ("Done at " & Tester_array(N))", i am able to get the files i need. However, when i remove this statement, no files can be retrieved. Why is that so? Can somebody advise ?
Option Explicit
Sub File_Transfer()
Dim N As Integer
Dim fs As FileSystemObject
Dim A As TextStream
Dim Lotid As Variant
Dim Testerid As Variant
Dim dRetVal As Variant
Dim Tester_array(1 To 15) As String
Tester_array(1) = "aaa"
Tester_array(2) = "bbb"
Tester_array(3) = "ccc"
Tester_array(4) = "ddd".......................
View 2 Replies
View Related
Aug 1, 2014
I am trying to create a number counter which runs up to a value which is determined by a COUNTIF Statement in the spreadsheet. I can get the number counter to run to the given value. However, due do formatting reasons I do not want the counter to start in cell A1 but A3 instead.
Essentially my code looks like this:
...
ActiveSheet.Cells(3, 1).Select
Dim i As Integer
For i = 1 To Range("A1")
Cells(i, 1) = i
Next i
...
View 3 Replies
View Related
Mar 23, 2007
I am trying to creat an IF formula for a spread sheet I am working on with information from Bloomberg. I am referencing sheet one to sheet two so I have that forumula in, but in some of the cells this symbol #N/A N.A. appears because some of the information is not available on Bloomberg. How can keep the referenc formula but also include a formula that basically says if #N/A/N.A. symbol appears to replace it with just NA.
View 9 Replies
View Related
Aug 15, 2014
I'm trying to make my life a little easier at work. Here is what I am trying to do. I'm trying to create a "calculator" that will tell me the date that a client will leave my program. I understand that I can simply do xx/xx/xxxx-15 and it will get me a new date, easy. Here is the kicker...My office only utilizes 30 day calendars. Regardless if the month has 28 or 31 days, in the eyes of my agency it will have 30.
i'm been trying to mess around with it for 3-4 days now and I can't quite figure it out. I have attached a sample spreadsheet what i'm i'm trying to do.
I would eventually like to create this to be a little interactive (like a pop up or something that is more user friendly) but i'm just itching to get it to work!
View 3 Replies
View Related
Dec 4, 2013
I am trying to create a formula that subtracts 1 hour if the value of cell E3 equals 11:00 PM.
This is what I've tried:
=SUM(E3-D3), IF(D3=11:00 PM, -1:00)
View 9 Replies
View Related
Mar 6, 2009
I have the records of a local angling club going back to 1932 and these records include the results of fishing matches matches held through that period. I want to analyze the catches of those matches in order to identify any trends that may exist on the river that those matches were fished and although I am reasonably computer literate I have never needed to use spread sheets.
If the data from those records were in metric measurement it would be no problem but they are in what I would refer to as Imperial measurement.
In other words they use measures in weight based on Pounds, Ounces and Drams.
There are 16 Drams in an Ounce and 16 Ounces in a Pound.
The software that is on my computer is Microsoft Excel Version 5.0c
View 14 Replies
View Related
Jul 21, 2014
I am creating a complex formula with UDF, this Hlookup is part of my complete formula. Meanwhile, I am working on this piece, not Sure what I am doing Wrong
I try to conver "MonthCurrent" Variable in a Year because the MonthCurrent is 06/01/2014, so will be Year(6/1/2014) = 2014
My Range called "DailyRates" is based per Year = 2014, 2015 ......
[Code]......
View 2 Replies
View Related
Apr 23, 2009
Basically I have a web page that I want to access with a command button http://www.wunderground.com/history/airport/KVTN/2009/3/28/DailyHistory.html
The only problem is that the address is date specific - the blue numbers and probably every time that I use the command, it will be a different date.
I used this formula
="http://www.wunderground.com/history/airport/KVTN/"&TEXT(R2,"yyyy/mm/dd")&"/DailyHistory.html"
and it gives me the right web address, I just need to figure out how to make it hyperlink to that web page and then use the command button to activate the hyperlink
This is the first time I have tried to hyperlink to a web page and am lost
View 2 Replies
View Related
Jul 14, 2008
Column A will be completely empty.
When an * is inserted into a single cell in column A, that Row number will become the variable in this equation:
=Sheet1!$G$'variable'
i.e. if i put a * in A14, then the formula should read (=Sheet1!$G$14).
View 10 Replies
View Related
Oct 10, 2008
I have a late report due @ work.... I have people who have worked for 4 days to get me numbers i need and they are not right.....
Anyways I have a spreadsheet with a whole lot of numbers on it... I need to add 30% to each number. What is the easiest way to set this up.
View 13 Replies
View Related
Dec 9, 2011
I am in the process of creating a template in excel with certain restrictions on the information that can be added to it. I've hunted several sites and forums to try and find a solution but find it difficult to see the best ones for my project. The template is roughly made up of say 10 references to large boxes, each box can hold smaller boxes. The smaller boxes vary in size. For example the large box is 60 inches long smaller boxes vary between 20 inches and 40 inches, can excel be made to tell me an error if i try to put 2 x 40 boxes in columns refering to 1 of the larger boxes as it exceed the maximum length of 60 inches?
View 2 Replies
View Related
Jul 31, 2014
I am using a vlookup formula to link 3 pieces of data together. I would like to insert a space between the 3 pieces. Currently formula result is:
item1item2item3
I would like it to view as:
item1 item2 item3
not sure how to alter the formula to create the space....
View 3 Replies
View Related
Nov 17, 2008
I am trying to create a formula by comparing data in columns on a separate tab.
Basically, I want to take the value of one cell in the primary tab, find the matching value in a column on another tab, then once it is matched, pull in the data from another cell in the second tab on the same row of the matched data.
View 9 Replies
View Related
Jun 28, 2006
Can i create a chart in excel just using a formula - but not data?
View 4 Replies
View Related
Jun 29, 2006
I cannot find the right catagorty I need to use to word this. I know there is a formula out there. I basically have 1k numbers I need to add into Collumn A of a worksheet - the numbers are from range 34-2501 through 34-3500. How can I get excel or VBA to do this automatically?
34-2501
34-2502
34-2503
repeat til
34-3500
Also, how to make it user friendly to create the same process over and over with a different set of numbers... meaning make it so I onlt have to input the range or numbers over and over. if it is an easy task I do this allot
View 3 Replies
View Related
Jun 24, 2009
I'm trying to have a Formula that I created in excel to be expressed through loop in VB.
Some parts of the Formula should remain constant, unchenged.
=IF(O2="","",VLOOKUP(Sheet1!A6,Sheet2!A1:O200,11,FALSE))
The parts of a code that are in red should remain unchanged though all 200 lines.
View 9 Replies
View Related
Apr 8, 2014
I have been trying to create a formula that will save me DAYS of messing around at work.
What I am trying to achieve is to have a sequence of numbers as follows:
BNA01A01 to BNA01A09 then have it change to BNA01B01 to BNA01B09.
This needs to be repeated for all letters to BNA01I09.
Then this sequence needs to be repeated to BNA12.
The last thing is for me to be able to change the formula in order to implement the same sequence on a separate sheet for BNB01A01 - BNB12I09 to BNL01A01 - BNL12I09
View 2 Replies
View Related
May 28, 2014
I need creating a formula for the following situation.
I need to link multiple arrays from different sheets. But am having a hard time concocting a formula that will work.
I have 2 columns of data on sheet1. For example:
A-------------B
apples-----1245
oranges----456
nuts--------384
etc.
Now, I need a formula that will sum the entire column B, by looking up the array of column A on another sheet and only summing the numbers on sheet 1 that also have a value of "West" on sheet 2. Sheet 2 looks like this:
A-------------B
apples------West
oranges-----East
nuts---------West
This needs to be functional as a template to be used each month - the entire point of the formula is to save time and eliminate the current (and lengthy method that is in use). I can tweak the formulas as needed. But am trying to avoid having to concatenate anything or do any modifications to the format of the sheets.
View 1 Replies
View Related
Dec 10, 2013
I have a formula which looks in a folder for a file and returns the cell I want from that folder and work book
='H:NCHOCall CentreCall Centre ResourcingStats[NHC_Telephony_Daily_2012-11-27.xls]NHC Daily'!$E$55
as you can see I have a date in the middle, I want it to reference to a cell with a date in and return the information from that document with the change in date. So all I have to do is drag the formula down and it will return the info i want out of each report.I think it might be an add on that I need to download?
View 1 Replies
View Related
Mar 24, 2014
I am creating a report and I am using the following Formula with condition.
(IN Q2 in the file attached)
=IF(P2="","Enter New to IMP check Date",DATEDIF(P2,C2,"d"))
Where in P2 is the START Date and C2End date.
P2 = 01 Jan 13
C2 = 10 Mar 14
When I apply the DATEIF formula its ignoring the year differ ace and give a result of 8 days not sure whats wrong here as the "Y" & "M" function works correctly and give proper result.
Sample attached : Book1.xlsx
View 7 Replies
View Related
Dec 14, 2009
In worksheet named, " My Overview", if the total sales values are a zero in C47:C59 the consultant name is duplicated in B47:B59 because of the values being a zero in C47:C59. How can i have the formula not duplicate this?
View 3 Replies
View Related