+ Reply to Thread
Results 1 to 10 of 10

Find Not working

  1. #1
    Registered User
    Join Date
    07-17-2014
    Location
    Edmonton
    MS-Off Ver
    2010
    Posts
    29

    Find Not working

    Hi there all,

    I have some code I have pieced together that I can't get past "If SearchWB.Worksheets(1).Cells(1, j) = "*Open*" Then"

    I have tried all sorts of different combos but to no avail.

    Essentially, i have a workbook of data that I want to search for the appropriate column to bring into my master workbook. Help getting this line of code working, and a look at the rest of the code, would be greatly appreciated!!

    Thanks in advance,

    David





    Please Login or Register  to view this content.
    Last edited by davidmhcampbell; 07-22-2014 at 02:12 PM.

  2. #2
    Forum Expert GeneralDisarray's Avatar
    Join Date
    09-15-2011
    Location
    Pittsburgh, PA, USA
    MS-Off Ver
    Windows Excel 2016
    Posts
    1,416

    Re: Find Not working

    Please wrap your code in tags.

    Edit your post, Highlight all of the code (and only the code) and press the "#" button.

    That will make the code easier to read and copy out.
    Remember, saying thanks only takes a second or two. Click the star icon(*) below the post you liked, to give some Rep if you think an answer deserves it.

    Please,mark your thread [SOLVED] if you received your answer.

  3. #3
    Registered User
    Join Date
    07-17-2014
    Location
    Edmonton
    MS-Off Ver
    2010
    Posts
    29

    Re: Find Not working

    Updated... Thanks

  4. #4
    Forum Expert Arkadi's Avatar
    Join Date
    02-13-2014
    Location
    Smiths Falls, Ontario, Canada
    MS-Off Ver
    Office 365
    Posts
    5,059

    Re: Find Not working

    your problem line is using wildcards... cant do that as far as I know... Are you looking for the word open in the cell? Iff so then try:

    Please Login or Register  to view this content.
    Please help by:

    Marking threads as closed once your issue is resolved. How? The Thread Tools at the top
    Any reputation (*) points appreciated. Not just by me, but by all those helping, so if you found someone's input useful, please take a second to click the * at the bottom left to let them know

    There are 10 kinds of people in this world... those who understand binary, and those who don't.

  5. #5
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Find Not working

    Please Login or Register  to view this content.

  6. #6
    Forum Expert GeneralDisarray's Avatar
    Join Date
    09-15-2011
    Location
    Pittsburgh, PA, USA
    MS-Off Ver
    Windows Excel 2016
    Posts
    1,416

    Re: Find Not working

    Instead of looping for the column with the word "Open" in the header, have you tried a .find()?

    Something like:

    Please Login or Register  to view this content.

    That will pinpoint the header you are looking for right away. Does that help? Once you have that header, would copy the contents by equating the values with something like:

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    07-17-2014
    Location
    Edmonton
    MS-Off Ver
    2010
    Posts
    29

    Re: Find Not working

    Thanks everyone for the replies...

    In the end I have found this to work...:

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Looks a lot like yours GENERALDISARRAY, just with using a function.

    I am about to start a new thread as I have hit another road block related to 'OVERFLOW'. I can't figure this one out as it goes deep into the process (loops at least 30 times) before this error rears its ugly head.... Stay tuned...

    Thanks Again,

    David

  8. #8
    Registered User
    Join Date
    07-17-2014
    Location
    Edmonton
    MS-Off Ver
    2010
    Posts
    29

    Re: Find Not working

    Posted twice for some reason??
    Last edited by davidmhcampbell; 07-23-2014 at 12:15 PM. Reason: posted twice?

  9. #9
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Find Not working

    Please Login or Register  to view this content.
    All integers should be change to long

  10. #10
    Registered User
    Join Date
    07-17-2014
    Location
    Edmonton
    MS-Off Ver
    2010
    Posts
    29

    Re: Find Not working

    That fixed my overflow error AB33...thanks!!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. VBA Find stopped working on Find Text (xlValue vs xlFormula)
    By ker9 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-11-2014, 10:31 AM
  2. [SOLVED] .Find working only when it wants to.
    By jstephens in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-22-2012, 04:45 PM
  3. Find not working
    By DebSki in forum Excel General
    Replies: 1
    Last Post: 06-13-2012, 12:41 PM
  4. Find - not working
    By johncassell in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 11-28-2008, 09:42 AM
  5. Find Next is not working for me.......
    By Tom in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-15-2005, 05:30 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1