You can use this in VBA.
strResult=Application.Vlookup(LookUpvalue,LookupRange,ColNumber,MatchType) Rajan From: excel-macros@googlegroups.com [mailto:excel-macros@googlegroups.com] On Behalf Of nitin arora Sent: Jan/Wed/2012 11:01 To: excel-macros Subject: $$Excel-Macros$$ Fwd: V lookup using macros Hi, I am facing a problem with Macro 3 in the sheets attached. At times the macro woks fine and at times it does not. The reason for the same is that when it does not find the date mentioned in Macro 3 it does not works fine. I was wondering if there is any way that the macro asks for a date to compare and if it does not finds that date then it should skip the step and proceed to next macro in call all macro. If you look at the sheet attached macro was unable to find date "1/3/2012" against researcher name. relevant extract: Jan 4 file: ActiveSheet.Range("$A$1:$X$15000").AutoFilter Field:=18, Operator:= _ xlFilterValues, Criteria2:=Array(2, "1/3/2012") Please let me know if you want any further details. It would be great help if I can get the solution for the same. Regards, Nitin Arora -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ---------------------------------------------------------------------------- -------------------------- To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com