Add Condition - If Value Is In Between Get Specific Text

Feb 1, 2014

I try to add some conditions to get specific text. i.e.

if cell b4 <= 20% then cell f4=01.30min
if cell b4 >= 21% and <=50% then cell f4=02.00 hr
if cell b4 >= 51% and <=70% then cell f4=02.30min
if cell b4 >= 71% then cell f4=03.00 hr

I tried different ways, including select case but unsuccessful.

View 8 Replies


ADVERTISEMENT

Find Specific Text In Cell That Matches Range Then Display Specific Text?

Aug 5, 2013

I'm trying to find vehicle make and model in a cell containing a lot of text and then display that in the formula cell. For example if A1 is a paragraph that contains somewhere within it "Ford" & "Ranger". I want B1 to display "Ford" and C1 to display "Ranger". I have a list of vehicles makes (column A) and models (column B) on a seperate sheet.

View 2 Replies View Related

Find Average With Very Specific Condition

Mar 14, 2014

Let's say I had the following data ...

47
50

50
50

44
50

46
50

Basically, I have 4 numbers, out of 50, as seen above...I want it so the last number (46 in this case) is special; what I mean by that is I want the following conditions to be met.

--If the special number is the lowest, just take the average of the four numbers, and divide it by 50
--If there is a (are) number(s) lower than the special number, then I want it to locate the smallest
---The smallest number should then be "replaced" by the special number (for calculations purposes only, not in the actual table)

So, in this case, since the special number (46) is not the lowest, excel would locate the lowest number (44), and calculate the average of 47, 50, 46, and 46 (the 44 was replaced by 46).

View 4 Replies View Related

Average Formula For A Specific Condition

Jul 30, 2009

I have been asked at work to get some averages of data from an excel sheet. I have attached a sample workbook of the data i will be using. On Sheet1 is the data that will be looked at and on sheet2 is a sample of the results i need to achieve. I can get the data on sheet2 easy if i knew that data was static but in my case the data is going to be dynamic, so i don't know how many records each person is going to have each time if that person shows up in the record set at all. This rules out on static ranges to gather averages.

So far what i came up with is i use a macro to copy all the "Names" column to sheet 2 and then filter that data so that each name is unique, sort like a "key" for looking up values. Now i need to get averages of "Total Hours" worked in sheet 1 and display it in sheet 2 for each "Name". I have a formula worked out and almost have it where i want it but cant seem to get the range of data i need to be looking at. I need to get the Average Of hours Worked Per Person Where "Wk End Date" is greater than 1/1/2008 and the "name" matches up with the name in sheet 2.

View 3 Replies View Related

Color Code -a Specific End Condition

May 12, 2007

I searched through the files and found a macro that works for me to color code my spreadsheets in Excle. Hwoever. How can I set it to stop when Cloumn G = the word "Created"?

Sub prettyPattern2()
Dim lRow As Range
For Each lRow In Range("A6:K500").Rows
Select Case lRow.Row Mod 2
Case Is = 1: lRow.Interior.ColorIndex = 34
Case Else: lRow.Interior.ColorIndex = 35
End Select
Next lRow
End Sub

View 8 Replies View Related

VBA Print Specific Pages Based On Condition

Jan 25, 2013

I'm looking to setup a macro that will print specific pages on the current worksheet. What pages will print in that same worksheet will be determined on the value of a specific cell.

Here is what I have that isn't working.

VB:
Sub Print_Specific_Pages()
'''''''''''''''''''''''''''''''''''''''''''''Prints only pages that contain data
''''''''''''''''''''''''''''''''''''''''''''
If Range("B3").Value = 0 Then
Worksheets.PrintOut from:=1, to:=1 'Prints page 1 when there is no data.

[Code] ......

View 5 Replies View Related

Working Out How Many People Reach Specific Condition

Dec 11, 2013

I've put together a spreadsheet look at the time taken for a vehicle to get from one building to another when called. I've set up conditional formats where the timings turn orange after 5 minutes and red after 10 minutes taken. What I also have to show though is who is taking the vehicle and break it down to show any delays to patients. Is there a formula that will automatically tell me when there has been a delay to patients?? Be amazing if there is as it would save me uber amounts of time as i have to collate a whole years worth of data!

I've attached a small sample of what I've done to show you how the spreadsheet looks.

sample.xlsx

View 5 Replies View Related

How To Copy Paste Specific Cells When Condition Met

Mar 13, 2014

I create a macro to copy cells for data starting from A4 to N4 from sheet - Register to 'Case History' when the cells in column N are 'Yes'. Also, would like to copy specific range from A-N and not the entire row. Please refer to the attachment.

Tracker Dept..xlsx

View 2 Replies View Related

Count Specific Criteria Based On Another Condition?

Jan 3, 2013

I'm trying to create a formula that tells me the following:

If the item is marked as closed (vs. active), then how many renewals/terminations replacements/etc are there? These are two difference columns in a worksheet.

View 2 Replies View Related

X Condition Lookup: Find The Specific Value Within The Table Or Array

Aug 21, 2008

Given three criteria (category, name and date) I want to find the specific value within the table or array. refer to attachment.

View 4 Replies View Related

Detect Cell Conditional Formatting State Of Specific Condition

Nov 26, 2009

Is it possible to check the conditional state for a specific condition for a specific cell.
For example a cell has 1 or more conditions.

A condition will toggle to a condition if true or false etc.
The specifics is i use red (color 255) if a cell has not met a specific condition (of 1 or more conditions)
So if the cell is mandatory to be populated, and is blank, it will be red, if not it will be something else.

But i want to loop all visible cells with conditional formatting, and where the cell has a condition when true will show interior color = to 255 return the cell address.
To msg the user where data entry is still required etc.

View 6 Replies View Related

Color Table Rows Where Specific Cell In Row Matches Condition

Jul 2, 2008

I have a selection on a worksheet that has 4 consistent columns (A, B, C, and D) each with a variable number of rows all containing string type data. With this data I want to use Conditional Formatting so that when I have a string value of X in column D for any row, that whole row with the X in column D has it's color change to say grey, this should happen regardless of what strings are in Columns A, B, or C.

Below is the way I've been trying to do this thus far and failing, when I run this code below I can only get it to grey out the cell with the X not the whole row.

Selection.FormatConditions.Delete
Selection.FormatConditions.Add Type:=xlCellValue, Operator:=xlEqual, _
Formula1:="=""x"""
Selection.FormatConditions(1) . Interior.ColorIndex = 16

View 4 Replies View Related

VBA Copy / Paste Specific Cells From A Sheet To Another Based On Condition (reference)

Nov 7, 2012

Basically, I need to copy and paste upon certain condition (references) and paste related-datas in another sheet corresponding with these references. Every references are organized by lines with indicators on columns.

In attached file, see:
- worksheet ANALYSIS:
* datas in E2, G2, D18, D19, D20, D21, D22 that needs to be copy based on reference in C2,
* then need to find this reference in worksheet called GROUP SAVE,
* and based on this reference, paste above cells value in corresponding "Indicators" column number

THEN, I will have to do pretty much the same with subgroup data. But I can figure out for this second step that request same manipulation.

View 3 Replies View Related

Formula To Count Dates Between 2 Date Periods If Specific Condition Exists

Apr 6, 2012

I am currently using this formula to count dates between 2 date periods If specific condition exists.

=COUNTIFS(
Data!S1:S100000,"*KP*",
Data!X1:X100000,">=10/1/2010",
Data!X1:X100000,"=10/1/2010",
Data!X1:X100000,"

View 3 Replies View Related

VBA Code For Adding A Specific Worksheet Condition Within Subfolder Consolidation Macro

Aug 22, 2013

The issue is the I want to put the condition here in my the code that only copies the desired cells if the sheet is named specifically such as "Jan", if not named as this the worksheet should not be used. The current code I am using was posted on this site in 2009: VBA to copy specified cells from all the files in a folder

My modified code is:

Option Explicit
Public strSourceFldr As String
Public EachFile As Object
Public objFSO As Object
Public objFolder As Object
Public objFile As Object
Public strSheetName As String

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

View 1 Replies View Related

Delete A Row If It Has A Specific Text In A Specific Column

Jun 21, 2006

I need a code that will delete a row if it has a specific text in a specific column.

In this case in column W if there is anything that starts with '>TC' I need that entire row deleted that its in.

View 7 Replies View Related

Replace Specific Numbers With Specific Text

Mar 13, 2008

Is there a way to make a macro convert '1' to Yes and '0' to No? I have 2 columns (F and G) in a worksheet that contain the value of 1 or 0, but I need to convert them to Yes or No. I have tried some fo the samples but they pop up a msgbox which is not required.

View 2 Replies View Related

If Condition With Multiple Text

May 27, 2014

I got four product name in column & want to bring other product name equal to same same product in different colum
like if products name in column range is PRV IT should bring birkett in other colum

PRV SHOULD BE IN NEXT COLUMN AS BIRKETT
TANK " " "" WAM
INSTRUMENT " " " " AGI
HVC " " " BAILEY
and rest of should be Marston

I had put that formula but didn't work 100%

=IF(C5>="PRV",IF(C5>="TANK",IF(C5>="INSTRUMENT",IF(C5>="HVC","BAILEY","AGI"),"WAM"),"BIRKETT"),"MARSTON")

View 8 Replies View Related

Add Text To All Worksheets If Condition Met

Jan 22, 2008

I have a macro that is supposed to type a text in column 8 if condition is met, on all sheets but one (" Total"). When I run it, it stops at "Next Line" with a "Compile error: Next without For". For the life of me, I can't figure out where I'm missing a "For".

Sub ForceMatch()
Dim ws As Worksheet
Dim line As Integer
endline = Range("A1000").End(xlUp).Row

For Each ws In Worksheets
If ws.Name <> "Total" Then
With ws
For line = 3 To endline
If (Cells(line, 9).Value <= 5000 And Cells(line, 8).Value = "") Then
With Cells(line, 8).Value = "FORCE-MATCH CANDIDATE < $5K ICDP"
Next line
End With
End If
Next ws
End Sub

View 9 Replies View Related

Excel 2003 :: Take Specific Text From Cell And Copy It In New One (Text And / Or Words Position Varies)

Jan 17, 2013

I'm having a 6000+ records, (contacts DB) exported in Excel 2003 format from MS Outlook.

Except the "First" and "LastName", all other contact elements are in the field "Notes" (which is the BZ column according to the exported outlook layout) multiplied by 6469 (records in total)

Useful information are included !!!

I'll give an example of a record...

Column: BZ, Row: 543 says --> "2110000000-6989000000, 1TOK_TER:17-11-010(25 DAYS LESS),
KATERINA 25 (MANTAS KALNNNNN_HYPERTENSION)1000-150, W:95_105, , HR THE 16wks_US NEFRON OK,
NT OK_B EPIP OK(GOLF BALL)_KAMPILI ORIAKI(DIAITA)_DOPPLER OK, O+,TEST OK(TOX_), , , , , , "

Now, I want every time to take the part of the text says "TER:something..." (part of which is date, but not every time with the known format dd-mm-yyyy, as you see here is yyy, followed by something else, with parenthesis here and maybe more data) and copy it in a new cell..., e.g:CO Column, same Row...

Above and every field which by the way is formatted as General (and it is text mainly) are made by merging older excel fields where data laid here and there, that's why you see the commas...with the method of a module with the following code:

Function MyMerge(Rng As Range)
For Each Cell In Rng
Temp = Temp & Cell.Value & ", "
Next Cell
Temp = Mid(Temp, 1, Len(Temp) - 2)
MyMerge = Temp
End Function

Note1:Records with the above string (TER:dd-mm-yyy) are 771 from 6469.
Note2: As an alternative solution I can see an extraction of the TER:dd-mm-yyy string and the copy in a new place, like the:CO Column, same Row...

View 9 Replies View Related

Macro To Only Show Rows That Contain Specific Text/Chinese Text Issue In Visual Basic ( 2007)

Jun 23, 2009

I want to create 3 command buttons (active X) on a worksheet to toggle between showing rows which only contain the below text in column L (range L9:L30) and showing all rows containg the options (However, I also have some blank rows in this range and i always want them to remain hidden.)

My text options are:

High ‚
Medium ՠҪ
Low ’á

The text arrives in the cells via a VLOOKUP

Is the chinese text a problem? i can't type it into VB.

I've been using the following macro to hide and unhide rows with a command button in the same sheet:

Private Sub CommandButton1_Click()
Toggle_Hide_Unhide
End Sub

Sub Toggle_Hide_Unhide()
Dim rngCell As Range
Dim TakeAction As Boolean

If ActiveSheet.CommandButton1.Caption = "Hide" Then
TakeAction = True
ActiveSheet.CommandButton1.Caption = "UnHide"
Else
TakeAction = False
ActiveSheet.CommandButton1.Caption = "Hide"
End If

For Each rngCell In ActiveSheet.Range("I9:I30")
With rngCell
If .Value = 2 Then .EntireRow.Hidden = TakeAction
End With
Next rngCell
End Sub

View 9 Replies View Related

Pulling Specific Text Within Text In Which Information Is Typed Differently?

Aug 2, 2014

I am trying to pull titles out of a text string but its quite difficult because of how the data was originally inputted. I need titles that appear in the following different formats

" title"
title/
title"

These titles were not inputted consistently and it could show up in the middle or at the beginning. I have attached a sample of the data that i am working with and a sample formula that i was trying to use to obtain my information. The formula that i have is a nested formula of find and mid formula that searches for the text within " ".

View 5 Replies View Related

Formula To Find Specific Text And Replace With Alternate Text?

Mar 4, 2014

I have a worksheet with several columns. I need a formula to search column D only and each time a specific location is identified to replace that location with alternate text. Example (ORIGNAL TEXT):

Column Dtext to text help.xlsx
BIRD
FISH
DOG
BAT
BUG

I need to search that listing and each time the word BIRD is mentioned have it replaced with FEATHERS and each time DOG is listed have it replaced with TAILS Final result would look like:

FEATHERS
FISH
TAILS
BAT
BUG

All other text should stay the same and replacement text should appear in the cell of the text it is replacing. This is a sheet used by multiple people several times a day and so the Find/Replace option really won't work.

Have working on this for at least 6 months and it just isn't going to happen for me. I thought I could use a Conditional format, but that is producing no results either.

View 3 Replies View Related

VLook Up Specific Text Within Text And Output Match From Table

Dec 3, 2009

Table 1:
I like to go to Berlin.
You like to move to Amsterdam.
They want to see Chicago.
When will the reach San Francisco.

Table 2:
Amsterdam
Chicago
San Francisco
Berlin

What I want to do:
I want my function to see if the text in Table 1 contains a value in Table 2, and if yes, output that value.

Desired Result:

Row A1:
I like to go to Berlin.
Row A2:
Berlin
Row B1:
You like to move to Amsterdam.
Row B2:
Amsterdam

View 9 Replies View Related

Proper Case Text By Condition

Oct 19, 2007

How can I extend proper() to NOT change "PO Box 333" to "Po Box 333". Ideally, I would like to supply a list of words such as PO and all the 2 letter directionals (NE,NW,SE,SW).

There are also cases such as a last name of MacNamara which should have a capital M and N. Even worse, I see that 3rd becomes 3Rd which is very sad.

I'm assuming the data was supplied in uppercase

View 9 Replies View Related

Specific Text In Column And Then Imputing That Text In A Cell?

Feb 3, 2014

So I have a column that will have the same text in all of the cells contained within it except for one cell. Is there a formula that I can use that will automatically find and transpose the text of the one cell that is unique out of the column? I was thinking of an IF function, but the column could be up to 60 cells in length.

View 1 Replies View Related

Creating A Report - Inserting Text And Row If Condition Is Met

May 16, 2013

What I need it for is an automated report that should be used for several different projects. Each projekt have events on different dates, and I only want the report to show a specific date if there is some text (i.e. event) on that date. As it is now, it's a looong report with several blanks with only a date showing. So it should insert a row (the tricky part) + the date + the text if condition is met, and do nothing if they are not. The script should add and remove rows and text depending on what project the information is taken from.

The data it should grab is in this form (many more data inputs though..):
Date Date Date
TEXT

And the report:

Date:

Date: TEXT

Date:

and should be like:

Date: TEXT

View 1 Replies View Related

Formula To Find And Substitute A Word In Text If Condition Met

Aug 18, 2014

In cell A1, I have three possible text strings: (1) "change/s: changed the color green to red", (2) "change/s: changed the color from green to red, changed the size from big to small", or (3) "changed the color from red to green".

I need a formula that will look at a text string, and if there is a comma in the string, it finds the word "change/s" and substitutes it with "changes", if it finds no comma, it substitutes the word "change/s" to "change", and if the word "change/s" is not in the text string at all, it leaves that text string unchanged.

View 4 Replies View Related

Excel 2010 :: Condition Formatting On Column Of Text?

Jul 22, 2014

I have a column of numbers that are already formatted as text. Some of the data is duplicate which is fine. It's like a list of 6000 numbers. I want to conditionally format the column so that I can fill the cell with a color as long as it stays the same number, but if it changes to a new number make it a different color. I don't need a lot of colors. Two is fine. TI have Excel 2010.

View 4 Replies View Related

Formula That Count Repeated Entries Given A Text Condition

Feb 14, 2009

i want a function that tell me how many duplicates are in the ID for a particular text.

View 9 Replies View Related







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