Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 06-07-2013, 10:58 AM
BobBridges's Avatar
BobBridges BobBridges is offline Macro Help Windows 7 64bit Macro Help Office 2010 32bit
Expert
 
Join Date: May 2013
Location: USA
Posts: 700
BobBridges has a spectacular aura aboutBobBridges has a spectacular aura about
Default


I hate the way this forum loses indentation. Well, let's take a look at this. va=R.Value creates a two-dimensional array and places all the UsedRange values into it, right? Then you start up a three-level loop and...

Wait, maybe I see the problem. Sheet2 contains, you said, one column and multiple rows, right? The statement "mynums = Sheets("sheet2").Range("a2:a226").Value" creates a two-dimensional array, but later on you're referring to "mynums(i)"; don't you have to refer to "mynums(i,1)"?

Also I think you're going to have to move the "End If" statement up one line, to be inside the For...Next group.

Oh, by the way, another time this question should probably be posted to the Excel Programming area, rather than this one.
Reply With Quote
  #2  
Old 06-07-2013, 12:58 PM
tmill29 tmill29 is offline Macro Help Windows 7 64bit Macro Help Office 2010 64bit
Novice
Macro Help
 
Join Date: Jun 2013
Posts: 3
tmill29 is on a distinguished road
Default

This did not work. The macro did not error but it did not do what it was inteneded to do. It is supposed to look at the value on sheet2 and see if any of those appear in sheet1 and then highlight the entire row on sheet1 if the values appear
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I assign a macro to a button when the macro is in my personal workbook? foolios Excel Programming 2 07-27-2011 02:41 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 02:56 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft