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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Fitlering in Visual Basic Report

Status
Not open for further replies.

reycons

Instructor
Mar 29, 2008
21
0
0
PH
I have a textboxt and which I input the lastname of a particular person like for example Cortez so all the record that has a lastname of cortez thats only it shows in the table

Can anyone give me a sample code in visual basic that filter the records in the table and that record that it filter thats the only record it shows in the report.

Thanks in advance....
 



Hi,
Code:
sSQL = "Select * "
sSQL = sSQL & "From YourTable "
sSQL = sSQL & "Where Customer='" & TextBox1.Text & "'"


Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 
If this is for a real-life application rather than an academic one, then search this site and google for 'sql injection'

___________________________________________________________
If you want the best response to a question, please check out FAQ222-2244 first.
'If we're supposed to work in Hex, why have we only got A fingers?'
Drive a Steam Roller
Steam Engine Prints
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top