Macro or VLookup? - Current VLookup Not Working

JFray

New Member
Joined
Jul 20, 2014
Messages
2
Office Version
  1. 365
  2. 2019
Platform
  1. Windows
Hi! I am new to VBA & Macros and didn't think I would get stuck on Vlookup, but here I am. I cannot figure out why it is not pulling in my date field from sheet 2. I have tried numerous things to try to make it work, but now seems like I am running in circles. Maybe a macro would be the better way to go with this request, but I just don't know how to even start. I've added a mini sheet below from "AUKYSCHEX" (aka sheet 1) so you can see what I am trying to do and "AUKYSCHEX1 (aka sheet 2) :)
I pull this data from 2 different reports that I run and paste into these sheets (columns A:M in sheet 1 and columns A:E in sheet 2). In AUKYSCHEX sheet 1 I added column N, using =right(M2,7) formula to extract the 7 digits from the text field. Followed by formatting column N to be number. Then concatenated column N and column F to make a distinct number to use for my Vlookup function in column P. Vlookup is to look in "AUKYSCHEX1" and return the date for the cell reference in column O in the 'AUKYSCHEX' sheet. I've tried cutting and pasting the lookup columns to the A position. I've tried removing formatting to see if I went to far with the formatting. Nothing has worked so far. Any help with this would be GREATLY Appreciated!!!!

Schedules Template.xlsx
BCDEFGHIJKLMNOP
1LineWO NoPriorityStart DatePart NoDescriptionWO QuantityQty CompUOMRun HrsReq/PromSO TextSO NoSO + ItemShip Date
2 FCT417A048326276004/13/211629642DH276 BLU 455 14gsmX850MM24,7600LB23.2704/15/2107527600752760075276001629642#N/A
3 FCT417A048326288004/14/211629642DH276 BLU 455 14gsmX850MM24,7600LB23.2704/16/2107527652752765275276521629642#N/A
4 FCT417A048322892804/15/211811977DH276 BL399.5X23.25 31.5" OD40,0000LB32.804/17/2107510685751068575106851811977#N/A
5 FCT417A048322893104/16/211811977DH276 BL399.5X23.25 31.5" OD40,0000LB32.804/19/2107510710751071075107101811977#N/A
6 FCT417A048322895004/18/211811977DH276 BL399.5X23.25 31.5" OD40,0000LB32.804/20/2107510723751072375107231811977#N/A
7 FCT417A058282300704/09/2116514534013 WHT 50GSMX970 A5 AV20,0000LB2404/11/2106871929687192968719291651453#N/A
8 FCT417A0582823010B04/10/2116514534013 WHT 50GSMX970 A5 AV20,0000LB2404/12/2106871929687192968719291651453#N/A
9 FCT417A108313664704/11/2117384194013 WH 50GSMX90MM GEN4 INLINE28,50023,004LB23.9404/13/2106871929687192968719291738419#N/A
10 FCT417A108305048904/12/2117384194013 WH 50GSMX90MM GEN4 INLINE28,5000LB23.9404/14/2106871929687192968719291738419#N/A
11 FCT417A108328174904/13/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/15/2106871929687192968719291789354#N/A
12 FCT417A108320135404/14/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/16/2106871929687192968719291789354#N/A
13 FCT417A108319509704/15/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/17/2106871929687192968719291789354#N/A
14 FCT417A108319509804/16/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/18/2106871929687192968719291789354#N/A
15 FCT417A108319509904/17/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/19/2106871929687192968719291789354#N/A
16 FCT417A108319510004/18/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/20/2106871929687192968719291789354#N/A
17 FCT417A108320141004/19/2116514554013 WHT 50GSMX1150MM RES (AV)38,0000LB23.9404/23/2106871929687192968719291651455#N/A
18 FCT417A108320141404/20/2116514554013 WHT 50GSMX1150MM RES (AV)38,0000LB23.9404/24/2106871929687192968719291651455#N/A
19 FCT417A1083249310A04/21/21RESERVEDRESERVED240EA004/22/21 RESERVED#N/A
20 FCT417A1083247968B04/21/21RESERVEDRESERVED120EA004/27/21 RESERVED#N/A
21 FCT417A1083201415C04/21/2116514554013 WHT 50GSMX1150MM RES (AV)38,0000LB23.9404/25/2106871929687192968719291651455#N/A
22 FCT417A108320142304/22/2116514554013 WHT 50GSMX1150MM RES (AV)38,0000LB23.9404/26/2106871929687192968719291651455#N/A
23 FCT417A108321016204/23/2117384194013 WH 50GSMX90MM GEN4 INLINE28,5000LB23.9404/25/2106871929687192968719291738419#N/A
24 FCT417A108313984904/24/2117384194013 WH 50GSMX90MM GEN4 INLINE28,5000LB23.9404/26/2106871929687192968719291738419#N/A
25 FCT417A108313985304/25/2117384194013 WH 50GSMX90MM GEN4 INLINE28,5000LB23.9404/27/2106871929687192968719291738419#N/A
26 FCT417A108321168004/26/2117384194013 WH 50GSMX90MM GEN4 INLINE14,2500LB11.9704/28/2106871929687192968719291738419#N/A
27 FCT417A108320136404/27/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/29/2106871929687192968719291789354#N/A
28 FCT417A108320137404/28/2117893544013 WHITE 50GSMX84MM INLINE27,0000LB24.5704/30/2106871929687192968719291789354#N/A
29 FCT417A108313985604/29/2117384194013 WH 50GSMX90MM GEN4 INLINE28,5000LB23.9405/01/2106871929687192968719291738419#N/A
30 FCT417A108313986104/30/2117384194013 WH 50GSMX90MM GEN4 INLINE28,5000LB23.9405/02/2106871929687192968719291738419#N/A
31 FCT417A288322227104/07/21RESERVEDRESERVED2880EA28804/19/21 RESERVED#N/A
32 FCT417A288311062304/19/211636190SWIFF SCRUB STRP GRN 70gX676MM40,2400LB67.204/22/2107453020745302074530201636190#N/A
33 FCT417A288323534404/25/211630793DH267 WHT 360 25gsmX59.25"35,0000LB44.804/27/2107511952751195275119521630793#N/A
34 FCT417A288326087204/26/211630793DH267 WHT 360 25gsmX59.25"35,0000LB44.804/29/2107524608752460875246081630793#N/A
35 FCT417A288326087504/28/211630793DH267 WHT 360 25gsmX59.25"30,0000LB38.405/01/2107524678752467875246781630793#N/A
36 FCT417A288322617904/30/211636041EASIFLEX 2001 CLR 120 3.8X61.55,6890LB10.9205/02/2107510259751025975102591636041#N/A
37 FCT417A3083247018A04/06/21184371351' LDPE LAM 2.00 OSY SBPP914914LM0.3504/06/21 1843713#N/A
38 FCT417A308321793104/11/211636246DH268 WHT 71 32gsmX61" TFX MR18,00015,653LB23.2204/12/2107514381751438175143811636246#N/A
39 FCT417A308321793504/12/211636246DH268 WHT 71 32gsmX61" TFX MR9,0000LB11.6104/13/2107514381751438175143811636246#N/A
40 FCT417A3083164541A04/13/211648587BL .001X72" LAM w CA-30 to 35"10,8160LM3.7304/13/2107480502748050274805021648587#N/A
41 FCT417A3083142584B04/13/2116360682500C BL 63 .005X12" . NO A/S8050LB1.3204/14/2107469424746942474694241636068#N/A
42 FCT417A3083142582C04/13/2116360662500C BL 63 .005X18" . NO A/S2,4150LB3.7904/14/2107469422746942274694221636066#N/A
AUKYSCHEX
Cell Formulas
RangeFormula
N2:N42N2=RIGHT(M2,7)
O2:O42O2=CONCATENATE(N2,F2)
P2:P42P2=VLOOKUP($O2,AUKYSCHEX1!$B$2:$E$1001,4,FALSE)



Schedules Template.xlsx
ABCDEF
1Order TypeOrder NoItem No.Ship DateProd TypeSO + Item
2SZ748830116295524/18/2021M74883011629552
3SZ749245716295524/21/2021M74924571629552
4SZ749571116295524/26/2021M74957111629552
5SZ750291316295525/1/2021M75029131629552
6SZ752387316295525/11/2021M75238731629552
7SZ753608616295525/17/2021M75360861629552
8SZ746692716295524/8/2021M74669271629552
9SZ752760016296424/27/2021M75276001629642
10SZ752765216296424/29/2021M75276521629642
11SZ752885816296455/3/2021M75288581629645
12SZ752327716296455/4/2021M75232771629645
13SZ752886016296455/5/2021M75288601629645
14SZ752886116296455/6/2021M75288611629645
15SZ753579016296455/7/2021M75357901629645
16SB6871929162966212/25/2021M68719291629662
17SB6871929162966312/25/2021M68719291629663
18SB6871929162968012/25/2021M68719291629680
19SO744630916297334/16/2021M74463091629733
20SO744632516297334/20/2021M74463251629733
21SO744629216297334/12/2021M74462921629733
22SO744636816297705/4/2021M74463681629770
23SO744637516297705/5/2021M74463751629770
24SO744640816297706/2/2021M74464081629770
25SO744638816297706/3/2021M74463881629770
26SB6871929162977112/25/2021M68719291629771
27SB6871929162977412/25/2021M68719291629774
28SO751531316297875/21/2021M75153131629787
29SO751531516297876/8/2021M75153151629787
30SO751531716297876/22/2021M75153171629787
31SO745422116297874/24/2021M74542211629787
32SO745422416297875/4/2021M74542241629787
33SO751531116297875/18/2021M75153111629787
34SO745426116297874/9/2021M74542611629787
35SO746545616298154/26/2021M74654561629815
36ST749775316298585/22/2021M74977531629858
37SO744626616298855/6/2021M74462661629885
38SO744627316298855/25/2021M74462731629885
39SO747922816305754/14/2021M74792281630575
40SO747924116305755/5/2021M74792411630575
AUKYSCHEX1
Cell Formulas
RangeFormula
F2:F40F2=CONCATENATE(B2,C2)
 

Excel Facts

Shade all formula cells
To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.
Your formula is looking for the value in O2 in column B on the other sheet. Since it isn't there (it's in F) you get no match. I think you want (based on your sample tables):

Excel Formula:
=INDEX(AUKYSCHEX1!$D$2:$D$1001,MATCH(($O2,AUKYSCHEX1!$F$2:$F$1001,0))
 
Upvote 0
Solution
Hi & welcome to MrExcel.
How about
Excel Formula:
=INDEX(AUKYSCHEX1!$E$2:$E$1001,MATCH(O2,AUKYSCHEX1!$F$2:$F$1001,0))
 
Upvote 0
RoryA Thank You SO Much! Using the Index & Match worked. Spot checking through my data and have verified the dates to be correct. Thank You!!!!!!! Have a Wonderful Day!
 
Upvote 0
Glad we could help. :)

(Almost 7 years to make your first post might be a record! ;))
 
Upvote 0

Forum statistics

Threads
1,215,425
Messages
6,124,825
Members
449,190
Latest member
rscraig11

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top