Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to Integrate Text Box with DataGris

Status
Not open for further replies.

Vincentan

MIS
Aug 21, 2002
52
MY
Hi Expertise! I have a problem here, I have a data entry form which create a find button for allow user to select the record by pop up the form with datagrid and return it to main form.

In the grid form I have text box and datagrid, I would like to integerate with datagrid where user keyin the text and datagrid will automatically find and scroll untill find the next near to match record.

Dim ConFind As New ADODB.Connection
Dim RscFind As New ADODB.Recordset
Public GetCode as string

ConFind.ConnectionString = "DRIVER={SQL Server};SERVER=SERVER;UID=sa;PWD=;DATABASE=MISDATA"
RscFind.ActiveConnection = ConFind.ConnectionString
RscFind.CursorLocation = adUseClient

RscFind.Open "Select vehicleno, vowner from vt_master ", , adOpenStatic, adLockOptimistic

Set GrdFind.DataSource = RscFind
GrdFind.Refresh
GetCode = RscFind!vehicleno

the following continue code your some expertise to help me to create [2thumbsup]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top