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!

Help needed for selecting the value from datepicker

Status
Not open for further replies.

swenri

Programmer
Jul 4, 2006
30
US
I have a query like in VB 2005

"SELECT DISTINCT c.coreid,n.nameplural,n.namecsalut,a.addrline1," & _
"a.addrline2, a.addrline3, a.addrcity, a.addrplace, a.addrzipcod,a.addrcntry " & _
"FROM corebio_full as c INNER JOIN name_full as n" & _
"ON c.coreid = n.nameid JOIN address_full AS a" & _
"ON c.coreid = a.addrid" & _
"WHERE n.nametype ='a' or a.addrlocatr='good' or a.addrmc1 ='y' and " & _
"a.addrforign ='Y' or a.addrforign ='USA'" & _
"and g.giftamount between val &('& txtMin.text &')& and val &('& txtMax.text &') &" & _
"and g.gifteffdat between Cdate (dtselectdate1.Value) and cdate (dtselectdate2.Value ) "

How should I allow the user to enter values and I need to get the resultset for amount and date between.

Any help is appreciated.
 
In VB6 you just need to put code in that checks to make sure the start date in less then the end date and that you have values there to work with. Then, put that under an event such as a button click, or, create a sub to run the code and call that sub under an event.
 
Thanks Captain. But , I need it in VB 2005.

 
You're in the wrong forum. Try forum796 (VB.NET)

________________________________________________________________
If you want to get 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
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top