am trying to write code to check if a cell contains specific text.
Basically, I hide all of the rows on the spreadsheet, and unhide them only if certain conditions are true.
Everything else, including first check is not a problem, it is just the part where I need to find specific text within a cell that contains various words.
Also, the cell I am searching for the text in is on a different sheet within the same book.
e.g.
------------------------
'Check for Specific parts
If Cells(intCount, 11).Value = "Yes" And ??(Does Cell 'x' (on a different worksheet) Contain the Word "Specific")? Then
'Select row
Rows(intCount).Select
'hide row
Selection.EntireRow.Hidden = False
End If
------------------------
What I am attempting to do is search if 2 cells contain specific text. For example in Column C I want to output "Yes" only if cell A and B are Yes otherwise the output is "No".
ABC 1YesYesYes 2YesNoNo 3NoNoNo
I have tried =IF(A1=B1="Yes", "Yes, "No") to no avail
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.
I have employee numbers in two ranges of cells where the employee number will have alpha and numeric (ASAZ002000). The first is a range of “target” employees we need to look at.(A4:A20). The second range will be all employees of the company that the target list needs to check in for the specific target employee(s).(G4:G25). If a “target” employee is found within the range of all (G4:G25) – highlight cell red (G4:G25). I have attached a small file that might explain it better.
I have two workbooks open, the first is a summary, the second has new data that needs transferring into the summary. Before transferring the data I need to check that 10 specific sheets exist in the file with the new data.
I have found some code that checks for one sheet name, but really need to check for 10 specific names, if any are missing then I need a message to appear, listing the missing ones and stopping the macro from proceeding,
Dim mySheetName As String, mySheetNameTest As String ActiveWindow.ActivateNext mySheetName = "Data" On Error Resume Next mySheetNameTest = Worksheets(mySheetName).Name If Err.Number = 0 Then
VBA to loop through all the cells, or an active selection, and if it finds a cell with a formula that starts with "=VLOOKUP" or "GETPIVOTDATA", then copy and paste values for those cells. If it comes across a cell that starts with "=SUM" then it leaves it as is. I've been looking for way to insert a wildcard to make this work, but can't seem to find anything.
I have a cell built into my spreadsheet that serves as an error check (i.e. returns the word 'ERROR' if certain criteria are fulfilled on the spreadsheet). I'm trying to write something into a Macro that will check this cell and not allow it to run if it states ERROR, returning a dialog box to notify this, is this possible?
I have a sheet in which some of the cells have two strings separated by a linefeed. I have come up with a cumbersome formula which will let me check if either of the two strings is a member of a list stored on another sheet. However, it fails if there is only one string in the cell, presumably as there is no linefeed for the formula to find. How can I modify the formula to cope with this situation?
There are also on occasions, three strings in the cell, but I can't seem to access the middle string with the formula. Simplified spreadsheet attached to show the problem. This must be formula-based, as we have a no VBA policy. If you think there is better way of doing this, please let me know.
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.
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)
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...
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
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 " ".
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.
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.
I have 2 tabs in a 2013 workbook. Inventory Receipts and lookups. One of the Data verification lookups I have is a drop down list in each cell in Column B (eg: Cat, Dog, Mouse) In the lookups tab I have another cell range containing the sounds (eg: Meow, Bark, Squeak).
What I am trying to acheive is, if B2 contains Cat, then return Meow in B3, if B2 contains Dog then return bark in b3 and if B2 contains Mouse return squeak in B3. Ideally I would like the formula to return the text from my lookup sheet (eg: 'Lookups'!C2,'Lookups'!C3,'Lookups'!C4). So depending on which option they choose from my animal drop down list .. the correct noise would automatically fill in.
I have 3 columns, C1, C2, C3. I have to return a value for the following conditions
1. Check for the presence of a particular text in the C 1 (duplicate values can be present) 2. Check for the maximum value in C2, if the second for the particular text from the first column (duplicate values can be present) 3. If the text is found, I need to return the Maximum value from column 3. Else I need to return 0.
My formula has been returning zero despite the fact that I have a larger valid value in column C3.
The formula(s) I have been running is 1. IF((AND(C1 = "E", Max(C2))), (C3),0) 2. IF((AND(C1 = "E", Max(C2))),MAX (C3),0) (In case of duplicated in C3) 3. IF((AND(C1 = "E", Max(C2))),MAXA(C3),0)
For all bank transactions I've downloaded, I would like to add a subject. The list contains many hundreds of rows, so I tried to make a macro for it. Unfortunately I cannot manage to search if a cell contains a certain text string. I came up to:
Can the below be achieved with any formulae or macro -
I have 2 worksheets (sheet1 & sheet2). In sheet2, i have some colors in column A (e.g. "red" in A1, "blue" in A2, "green" in A3.
In sheet1, i have some text strings in column A, e.g.
A1: I love red color A2: my pen in blue A3: Green grass A4: Orange juice A5: I like red and blue
What i want in corresponding cells in column B, is the name of the color which is in column A. so my output should be
B1: red B2: blue B3: green B4: "NIL" (any error message) B5: red (even though it contains 2 color, i am happy to show any one of the colors it contains)
I want to write a formular to initiate an action if a particular text is not in a list For example, I have a list in column D1:D50, and I want the following to happen in say cell A1
If "apple" is not in list D1:D50, then in put "N" in cell A1, else input "Y".
I'm trying to identify if text contained in one cell is also contained in another cell. I used the following formula with some success, but it is not successful in all situations, and I don't know why.
I have a textbox in a form and i need to check if the text posted there begins with zero or if it contains spaces. Ex:
05E 9050 01 if this is the text then it shoud warn me becouse there is a zero in the begining and it contain spaces 4P 565001 if this is the text then it shoud warn me becouse there is a space
I'm on a time crunch and can't remember or seem to be able to find how to check if a value stored in a variable is a number or is text.
I want to be able to define QTY under the general public definition with no designation (i.e. integer, date, string...so on.)
The variable QTY could be anything and I grab some parsed data from a cell, if it is filled with a number I want to keep it, if not I want to delete it.
I know how to keep it or delete it, I just need to know how to check for integers...(check to see if it is a number from the keypad...I can still store it as text -- maybe integer isn't the best word).
I see you (whomever you is) fixed the "Deletked" in the message box...it is now Deleted. I can't give you a hard time about not following the rules now.