•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Visual Basic 4 / 5 / 6 section within the Software Development category of DaniWeb, a massive community of 329,722 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,538 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Visual Basic 4 / 5 / 6 advertiser:
Views: 19239 | Replies: 15
![]() |
•
•
Join Date: Feb 2005
Location: Braintree, UK
Posts: 1,150
Reputation:
Rep Power: 7
Solved Threads: 57
•
•
Join Date: Apr 2008
Posts: 6
Reputation:
Rep Power: 0
Solved Threads: 0
Hi,
Ok try this syntax
Take an variable of type serch data.
dim str as string
Now take an inputbox code as follows
str = inputbox ("Enter Name","Search")
then,put statement as follows
adodc1.recordset.find "<Field name>='"& str &"'"
if the searching record is a Number type then type as follows
adodc1.recordset.find "<Field name>='"& val(str) &"'"
then put condition to check record found or not
if adodc1.recordset.eof then
msgbox "Record not found"
else
text1.text = adodc1.recordset.fields(0)
text2.text = adodc1.recordset.fields(1)
endif
Remember that the value of fields is order by it is actual in database
Ok try this syntax
Take an variable of type serch data.
dim str as string
Now take an inputbox code as follows
str = inputbox ("Enter Name","Search")
then,put statement as follows
adodc1.recordset.find "<Field name>='"& str &"'"
if the searching record is a Number type then type as follows
adodc1.recordset.find "<Field name>='"& val(str) &"'"
then put condition to check record found or not
if adodc1.recordset.eof then
msgbox "Record not found"
else
text1.text = adodc1.recordset.fields(0)
text2.text = adodc1.recordset.fields(1)
endif
Remember that the value of fields is order by it is actual in database
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
DaniWeb Marketplace (Sponsored Links)
- Previous Thread: How to Store Image in Oracle 9i using VB6
- Next Thread: final project



Linear Mode