Insert A Number Based On A Text Value
Oct 13, 2009
I have a cell (B4)that may contain several different text values, i.e. Bill, Tom, John, Mike, Larry, & Dan. The value in cell D4 needs to relate to what text is in B4, i.e Bill = 6; Tom = 12; John = 8; Mike = 20; Larry = 15; & Dan = 10. I was trying an IF statement, but having trouble.
View 2 Replies
ADVERTISEMENT
Sep 24, 2008
I can't seem to make user-defined format that puts a text in front of a number and/or a text.
Let's say I have A1: 13, A2: texttext A3: text7 and I want to format a lot of cells to "Ilike 13" / "Ilike texttext" / "Ilike text7"... ie add the same text in the front of the cell, no matter what the content is.
I did manage it seperately, with "texttext" @ for text and "texttext" # for numbers, but what's the general one?
View 12 Replies
View Related
Mar 17, 2014
I have the following datas as an example;
A1: %90
A2: %100
A3: %75
According to those datas I want to get the following results;
B1: On going
B2: Done
B3: On going
So basically I want to tag columns which are equal to 100% as "Done", and the rest is as " On going".
View 2 Replies
View Related
Jan 31, 2008
I have a spreadsheet which contains data needing to be re-formatted into a suitable format for my database. So far I have been doing this by hand, but want to make it quicker as I have over 2000 lines to sort out. I am trying to write a macro that determines whether there is data in the column next to the active one (D2), and if there is counts how many columns there is data in. Once it has done this it needs to insert the same number of rows as there are columns, then copy the column data and transpose it into the empty rows. My macro seems to work at first, but it exits after around the 4th row, but I can't work out why.
Sub split_For_Database()
Dim No_Of_Cells As Integer
Dim Start_Cell As Range
Dim Cell As Range
Dim LastRow As Range
Dim i As Integer
Dim lRows As Long
Set LastRow = Range("C65536").End(xlUp)
i = 0
Set Start_Cell = Range("C2")
Set Cell = Start_Cell
Do While Start_Cell.Address <= LastRow.Address
Do While Cell.Offset(0, 1) > 0
i = i + 1
Set Cell = Cell.Offset(0, 1)
Loop...................................
View 8 Replies
View Related
Apr 23, 2014
I have an excel sheet that I've automated for my shop ... Basically it copies a set of rows from one sheet, asks for which cell you want to start the paste at, then pastes it... Here's what I have so far:
[Code] .....
So I tried to use a variation of strReturn to indicate number of rows wanted but that didn't work ... Basically I'm going to create the "data" to include 50 rows, but have it selectable for the user to say they only want 5, 7 or 29 rows ...
View 2 Replies
View Related
Feb 20, 2009
Column B contains geographical Areas. Column C contains a list of business departments.
North Env
North Env
North Ops
North Sales
North Sales
North Sales
South Env
South Maint
South Ops
South Sales
South Sales
South Sales
Etc.
The values and number of these departments will vary. I want to insert lines to sum the totals at the bottom of each geographic area based on the number of different departments. So, for this example, for the North three lines would be inserted. For the South, 4 lines would be inserted.
View 4 Replies
View Related
Mar 12, 2008
I have an excel sheet that looks like this:
IMAGE 1
(The sheet holds more data but not needed for this)
I have two buttons; “BUY” and “SELL”
I need a vba-code that inserts either “BUY” or “SELL” in row 6 (buy/sell) and insert a text (code) in row 7 depending in this information. When I push either “Buy” or “Sell”
IMAGE 2
So.. When I push the button “SELL” (already made) the action “Switch” should get “Sell” and actioncode “SO”, and “Redem1” and “Redem2” should get “Sell” and actioncode “RA” and “RN”
So.. When I push the button “BUY” (already made) the action “Switch” should get “Buy” and actioncode “SI”, and “Subsc” should get “Buy” and actioncode “SA”
(When the button is pushed I have a autofilter that “hides” either all the “sell” or all the “buy”)
IMPORTANT: There is NO range!! the list goes on, and changes so I need it to work on x amount of rows. !
View 3 Replies
View Related
Nov 20, 2009
I'd like to adapt my macro so that it would insert a blank row after it detects the the first 16 characters of text as "'Closing Balance"; or it could even detect "'Closing" as the first 8 characters if it would be simpler
The Data Begins in Row 5 of Column A
My Current Macro is as below which I have adapted from another one I used
It is not working since it is detecting for the exact text "'Closing Balance" whereas the data registry would write "'Closing Balance as at 31/10/2009" , of which the "as at dd/mm/yyyy" portion would change every time a report is exported, but the first part "'Closing Balance" or even just the word "'Closing" will always be the same.
View 6 Replies
View Related
Feb 20, 2014
I regularly run a report that comes out in a slightly different format each time depending on whether or not there is data for specific criteria. for instance (sample attached): criteria a, b, and c are in rows, 1, 2, and 3 in columns. a, b, and c are expected to repeat themselves several times. if there is no data in one instance of b then you may see something like abcacabc.
I'd like to loop through each row in column a, check to make sure that it is the correct value (either a, b, or c) and if not, insert a blank row so I can then copy the data to my final project without having to worry about formatting.
the example above would then become abca cabc
View 3 Replies
View Related
Oct 10, 2011
Im trying to make a simple macro for cataloging some equipment and where its located.
I've created a user form where there is a free text field for Equipment. Instead of just inserting this entry into the first available cell, i would like for it to place it in the first available cell under the corresponding first letter of the equipment to the named worksheets A-Z.
I have named the worksheets A through to Z, and upon entering the free text 'Equipment' name, say for instance Trolley, for it to recognise the T, open the worksheet named T and insert the equipment name and location etc across the first free column.
View 4 Replies
View Related
Jan 18, 2013
Is it possible to insert text as a comment on another sheet based on a date?
I have Sheet 1, that has 3 columns, Name, Date, Reason
Sheet 2 is a monthly calendar with the dates in E5:AH5 and the names from D6:D10.
What I am trying to do, is when they enter their name, date and reason on sheet 1, I want the reason to to be inserted on sheet 2 as a comment in the cell that matches the date and the name.
View 1 Replies
View Related
Aug 3, 2012
Is there a function that allows you to read column A for an ID (these may or may not include letters/numbers/"?", are non-sequential and are of variable lengths) and, if it is the first time that it has seen an ID column B will read "sample_1_arm_1", if its the second time it has seen an id it will read "sample_2_arm_1", etc? An example of what I am trying to do on a much larger scale:
id
event_name
C83-858
sample_1_arm_1
[Code].....
View 3 Replies
View Related
Jul 25, 2006
I am designing a from with a variable number of titles. The user should be able to insert a title into a column by typing in the title that he wants into a text box, and pressing a command button that I have created ( named add). The problem arises when I try to get the text to lie vertically as opposed to horizontally (in the cell, not as a text box. If this can only be done as a textbox, let me know). Is there any way to do this?
View 5 Replies
View Related
Mar 28, 2014
I have a column C with different text in cells (item's title). Column D - relevant description for each of the items. 100+ rows.
Now, unfortunately, often a spreadsheet with items is updated with many new items. So I get a new spreadsheet with old and new items mixed. I need, somehow, to import descriptions of the old items (Column D of the old spreadsheet) to the new spreadsheet from old spreadsheet. So I want excel to look for old items in column A of the new spreadsheet and, once found, insert a description in the column B from old spreadsheet.
See attachment : Example for forum.xlsx
View 3 Replies
View Related
Aug 14, 2007
I have a problem of having to repeatedly copy and paste a series of data based on the number of occurrences in each row of data series. For instance:
[Road Name] [Building Name] [No. of occurrence]
(1) [Scotts Rd] [Tangs Building] [38]
(2) [Orchard Rd] [ABC Building] [3]
(3) [French Rd] [DB Bank] [1]
I will need to duplicate (1) 38 times with the location name and building name. Similarly, I need to duplicate (2) 3 times. How can I simplify it programmatically?
View 3 Replies
View Related
Aug 27, 2007
I have a range of some 2,000 plus cells that are various numbers in them only. What I want to be able to apply is a macro that will look at the number in a cell and if the result is between a set range, produce a text, eg.
If the number is between 0 - 999 then insert text [url] this is where you go'.
If the number is between 1000 - 1999 then insert text [url] this is where you go 2'
If the number is between 2000 - 2999 then insert text [url] this is where you go 2'
etc.
I have up to 11 ranges of numbers to insert (up to 10000 - 19999).
So the text is the result of the formula.
View 9 Replies
View Related
Jan 25, 2008
I want to be able to return a text string of either Trainee 1 or Trainee 2, (or default to other text) based on codes that are 4 digits (DD01, KKB1, KKB2, KKC2, GG03, etc, where starting with K and ending with 1 or 2 is the criteria for TR 1 or TR 2 . There are two many KK** items to list them all in an If statement and I can't seem to use a wildcard.
=IF (right(c1,1) = "1", "Trainee 1", B1)
gets me halfway there I think but of course doesn`t pick up Trainee 2 and also returns Trainee 1 when it sees DD01.
View 7 Replies
View Related
May 15, 2008
Cell L90 to L120 are input cells where I type " Percentage" or "Dollar Amount". I need the five cells to the right of each input cell starting two cells over, to be formatted accordingly. I read a thread similar to what I'm asking for suggesting a worksheet change macro, but I can't quite figure it out for a range of cells. Also, in case I need to add a row to my sheet before all of these cells, how can I make sure that this will still work without having to go into the code. Is this an activecell thing?
View 5 Replies
View Related
Jun 15, 2014
I am trying to display result of risk assessment matrix in excel. I have three columns PROBABILITY , IMPACT and RISK RATING (probability *impact).
Probability = Very Low(1), Low(2), Medium (3), High (4), Very High (5)
Impact = Low(1), Medium(2), High(3)
Risk Rating = Low (value between 1 -3), Medium (value between 4 - 6), High (value between 7 - 15)
Is there any way that I just use TEXT in the cell (visible to user) and excel does its magic in the background using the numbers that I have for each TEXT? I don't want to display numbers.
View 2 Replies
View Related
Feb 27, 2014
I have two columns in a spreadsheet that I want to use an IF function with. In the first column, I want a pick list containing 5 text options. Depending on which option is chosen, I want a number to auto-populate in the second column.
The numbers are important, because I want to repeat this pair of cells with slightly different text values in the second pair, and then to have a column that multiplies the two resulting numbers and conditional formats the result.
View 14 Replies
View Related
May 14, 2014
I have a form in work which acts as a tick sheet for tasks complete on a construction site. When a task is complete I copy & paste from a key of dates i.e. week ending 11.05.15, this allows me to see what week a task was complete.
Generally I only marked off tasks which were 100% complete but my manager wants me to enter the % of the task complete also, i.e. 80% in the box.
So my question is how can I have the formula assume that any box with a date & shading is 100% and any cell with a number i.e. 80 is only 80% complete. I need it to monitor around 150 cells and give me the overall % complete based on what i have discussed.
View 5 Replies
View Related
Jan 25, 2013
I am wondering if I could have a formula be used against a certain row/cell containing a certain "phrase" or "number" for instance
I want E1 to read something like this = (row containing item "FF32105") (the given row from the previous statement) ( the input column ex. B) (the input value ex. *6)
Essential I want to be able to copy and past a sales forecast and have the formulas automatically (listed below the pasted forecast) calculate purchase needs. The issue is that if our forecast one month has a certain item and then the next does not then they will end up on different lines after the copy/paste. We have over 500 items so a manual adjustment would be time consuming..
Is there a possible way for the formulas to "find" the correct line to start calculating data?
View 6 Replies
View Related
Jul 29, 2013
I have been trying to format the rows on this sheet to color scale red based on the number of repeat text strings in Column E. Referring to the attached example sheet, '321/312.2/321.3' appears the most times and the goal is to color code the rows it appears in the deepest shade of red, then the next highest occurring string would shade the rows it appears in a lighter shade, etc, in descending order. Our team currently does this across multiple sheets manually everyday and it would be a real time saver if we could get excel to do this automatically.
View 14 Replies
View Related
Feb 16, 2014
I have a time sheet in which i need user to enter a time sheet number in cell c14
I need a formula for that cell so the user can input the time sheet number but only be able to do this if the time sheet number they are imputing is the next number in sequence of the last one used.
View 1 Replies
View Related
May 2, 2007
I need this for a tracking sheet of scores. For example, 1 gets 100 points, 2 gets 90 points, 3 gets 80 points, etc. I need to set it up for 10 places. I have no idea and have fiddled with it for two hours now. I need to be able to put a 1 in the cell and 100 appears after I hit enter, etc.
View 5 Replies
View Related
Oct 12, 2011
I have three colums on a spreadsheet the have a formula that calculates by taking the amount dividing it by 365 days then multiplying that by say 35 days. The day portion of the formula is the same in all cell in the three columns the number is the one this that changes by cell.
Is it possible to have a pop up box allowing the user to enter a number that will then be inserted into the formula. Instead of hitting F2 and manually entering the number.
View 3 Replies
View Related
Jun 10, 2014
I've create an userform with 2 textbox and a command button.
The user is allow to paste an article into textbox1, when they clicked the button, it should be able to find a specific text string in the article, then right after that text I want to insert addition note and a new article with notes will be generated in textbox2.
Currently i stuck on how to insert the note after the specific text string?
View 1 Replies
View Related
Oct 8, 2008
I have a column that I want to insert number 1 through ? incrementing by one. Can I do this simply without having to type in each one manually?
View 4 Replies
View Related
May 21, 2009
somehow i managed to do this at first and then forgot to save my personal work book and cant remember how to do it.
What it is, is if cell A1 has a certain phrase in it ie Customer Reference then i want to insert four columns before it so it ends up in cell E1.
The other thing which i never managed to do is. I have 5 workbooks. master, book 1-4. I want to past all info in columns A:T from Book 1-4 into Master in the next available row.
View 10 Replies
View Related
Nov 11, 2011
I've a list (Taken from this website; [URL] of 4900 rows with each row have 4 numbers if I want to add or insert one number( from 1 to 50 ) to each row with no duplicate to make it 5 numbers in each row? Is there a formula or Vb code to do this?
Code:
123411256212783129104121135512123161213147121543812162191217471012181911122023
12122230131224501412253315122641161227491712284218122932191234462012364421
1237392212384523124048241359251368261374427131013281311272913123630
[Code]...
To my calculation Numbers (1:50) have to be use 98 times;(50*98=4900) since each numbers in the list used 392 times(392/ 49 = 8)since there is no duplication when adding numbers (1:50) to rows each numbers must pair with evry other number in that list 8 times.at the moment with out adding the 5th number each number pairs with any other number exactly 24 times but adding process finish it should be 32 (24+8).
View 9 Replies
View Related