Novice VBA User needs help with using data from input box for Cell Find

Hey all, what I'm trying to do is take data that is entered by the user in a InputBox and using it in a cell find. However, my code doesn't work. Any thoughts/ideas Thanks!


Dim Message, Title, MyValue
Message = "Which channel name do you wish to choose "   
Title = "ChooseOriginalChannelName"   
MyValue = InputBox(Message, Title)
       Cells.Find(What:="MyValue", After:=ActiveCell, LookIn:=xlFormulas, LookAt:= _
        xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:=False) _
        .Activate

 


Answer this question

Novice VBA User needs help with using data from input box for Cell Find

  • st23am23

    Remove the quotes from MyValue in your Cells.Find call.

    Hope this helps,
    Josh Lindenmuth

  • easan

    Yep, that did it. Thanks so much for you help!


  • Novice VBA User needs help with using data from input box for Cell Find