LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Userform for data pull

Good day to all!

I am trying to import data into my simple 2-field userform using a lookup
function. In the first field, I enter my criteria. Then I click the "Find"
button to look this up in a range. However, the data doesn't come into that
field and I get an error msg saying runtime error 424, object required. Here
is what I have:

Private Sub FindButton_Click()
Dim x As Range, y As Range
Dim cb As String
Set x = Worksheets("Table").Range("B2")
Set y = Worksheets("Table").Range("B65536").End(xlUp).Offs et(0, 7)
cb = Box1.Value

Application.WorksheetFunction.VLookup(cb, Range(x, y), 2, False).Select
= _ Box2.Value

End Sub

Thank you for your assistance!!

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
VBA: Pull Record Into UserForm Mcasteel[_15_] Excel Programming 1 October 27th 04 12:50 PM
VBA: Pull Record Into UserForm Mcasteel[_13_] Excel Programming 1 October 27th 04 07:16 AM
VBA: Pull Record Into UserForm Mcasteel[_10_] Excel Programming 2 October 26th 04 11:03 PM
VBA: Pull Record Into UserForm Mcasteel[_7_] Excel Programming 2 October 26th 04 06:27 PM
pull down menu on userform Tom Ogilvy Excel Programming 4 August 13th 03 12:49 AM


All times are GMT +1. The time now is 08:35 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"