Validate Cells Against 2 Values In Different Sheet Via VBS

slewitan

New Member
Joined
Apr 22, 2013
Messages
2
Hi,
I need to validate sheet1 against sheet2 that the values in columns sheet1 F-G will match sheet2 D and shhet1 B will match sheet2 A.
Basically I'm trying to recreate something similar to: {=INDEX(Sheet2!$C:$C,MATCH(1,IF(Sheet2!$A:$A=$B2,IF(Sheet2!$D:$D=F2,1)),0))} (I'm not using this b/c it would make the spreadsheet difficult for the end-user to use.)

Other (nonessential for the answer) Details:
1. Non-Valid: Red
2. Valid: White
3. Validation should (if possible) be case insensitive
4. Sheet1's validation will always start in F but different applications will vary in columns length.
5. Sheet2's list is connected to a refreshing data connection and will grow over time.

Excel 2007/Windows XP
ABCDEFGHIJK
Application NameApplication IDFirst NameLast NameUsernameReqPOReceiveInvoiceApproveAccount Group
App1John1Doe1jdoe1WWWWN/AMarketing
App1John2Doe2jdoe2WRWRN/AStore display
App1John3Doe3jdoe3N/AN/AN/AN/AWIS and GP
App1John4Doe4jdoe4WRWRN/AIS
App1John5Doe5jdoe5WWWWN/AGradus
App1John6Doe6jdoe6WRWRN/AAll
App1John7Doe7jdoe7N/AN/AN/AN/AWStore Ops
App1John8Doe8jdoe8RRWRN/AIS
App1John9Doe9jdoe9RRWRN/AIS and GP
App1John10Doe10jdoe10RRWRN/AMarketing
App1John11Doe11jdoe11WWWWN/AIS and GP
App1John12Doe12jdoe12N/AN/AN/AN/AWIS
App1John13Doe13jdoe13N/AN/AN/AN/AWLegal
App1John14Doe14jdoe14RRWWN/AAll

<tbody>
[TD="align: center"]1[/TD]

[TD="align: center"]2[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]3[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]4[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]5[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]6[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]7[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]8[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]9[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]10[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]11[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]12[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]13[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]14[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]15[/TD]

[TD="align: right"]1[/TD]

</tbody>
Sheet1

Excel 2007
ABCD
Application IDApplication NameOption IDOption Value
App1Advertising
App1N/A
App1W
App1R
App2View, Update
App2View, Add, Update, Delete, Copy
App2View

<tbody>
[TD="align: center"]1[/TD]

[TD="align: center"]23[/TD]
[TD="align: right"]1[/TD]

[TD="align: right"]19[/TD]

[TD="align: center"]24[/TD]
[TD="align: right"]1[/TD]

[TD="align: right"]3[/TD]

[TD="align: center"]25[/TD]
[TD="align: right"]1[/TD]

[TD="align: right"]2[/TD]

[TD="align: center"]26[/TD]
[TD="align: right"]1[/TD]

[TD="align: right"]1[/TD]

[TD="align: center"]27[/TD]
[TD="align: right"]2[/TD]

[TD="align: right"]43[/TD]

[TD="align: center"]28[/TD]
[TD="align: right"]2[/TD]

[TD="align: right"]42[/TD]

[TD="align: center"]29[/TD]
[TD="align: right"]2[/TD]

[TD="align: right"]41[/TD]

</tbody>
Sheet2
Thank you for your time.

P.S. Cross-posted last week at Validate Cells Against 2 Values In Different Sheet Via VBS
 

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