Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
It sounds simple but its really causing me problems.. Here is what I am
currently having to do.. If Range("J2") < "Warn" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Warning" End If If Range("N2") = "PSSNAP" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Sales" End If If Range("L2") = "2669" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Warning" End If Ok. This list goes on an on.. I basically have about 15 more strings like this to add on.. Is there not away to have the macro search through the columns and have it input my answers on the corresponding cell in column "Q" if the data from column J/L matches what i need? I need help on this bad. ASAP. Thanks a ton! |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Not exactly sure what you want but this idea might help. NO selections.
if range("j2")<"Warn" or range("N2")="PSSNAP" or _ range("l2")=2669 then range("q2")="Warning" -- Don Guillett SalesAid Software "cbanks" wrote in message ... It sounds simple but its really causing me problems.. Here is what I am currently having to do.. If Range("J2") < "Warn" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Warning" End If If Range("N2") = "PSSNAP" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Sales" End If If Range("L2") = "2669" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Warning" End If Ok. This list goes on an on.. I basically have about 15 more strings like this to add on.. Is there not away to have the macro search through the columns and have it input my answers on the corresponding cell in column "Q" if the data from column J/L matches what i need? I need help on this bad. ASAP. Thanks a ton! |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Find would not be any simpler in terms of the code.
You can simplify your code though If Range("J2") < "Warn" Then Range("Q2").Value = "Warning" If Range("N2") = "PSSNAP" Then Range("Q2").Value = "Sales" If Range("L2") = "2669" Then Range("Q2").Value = "Warning" -- HTH Bob Phillips (remove xxx from email address if mailing direct) "cbanks" wrote in message ... It sounds simple but its really causing me problems.. Here is what I am currently having to do.. If Range("J2") < "Warn" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Warning" End If If Range("N2") = "PSSNAP" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Sales" End If If Range("L2") = "2669" Then Range("Q2").Select ActiveCell.FormulaR1C1 = "Warning" End If Ok. This list goes on an on.. I basically have about 15 more strings like this to add on.. Is there not away to have the macro search through the columns and have it input my answers on the corresponding cell in column "Q" if the data from column J/L matches what i need? I need help on this bad. ASAP. Thanks a ton! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do i build a search table in excel | Excel Worksheet Functions | |||
build a search tool in excel | Excel Discussion (Misc queries) | |||
Search open sheets in workbook and insert into open sheet | Excel Discussion (Misc queries) | |||
Search within workbook | New Users to Excel | |||
FAQ Spreadsheet with search function | Excel Discussion (Misc queries) |