i Have done this code before for a project i did months ago but when i tried to do the same code for another project it just gives me a error please look at this code and tell me if there is another way of doing this.
to give you a background of what it is i'm trying to do i have place a datalist & a datagrid & two ADODC controls on a form what i want to do is fill the datalist with name i have in a database i have made and update the datagrid with it's information when i click on a name in the datalist.
so after i have bounded the ADODC controls to there rightful places i have used this code for the click event for the datalist:
but when i use this code it keeps giving me an error (Syntax error in from clause) i am sick of seeing this error when i use this code. anyway i think i have done everything right? if i haven't and i have left something out please point this out to me..
lee123
to give you a background of what it is i'm trying to do i have place a datalist & a datagrid & two ADODC controls on a form what i want to do is fill the datalist with name i have in a database i have made and update the datagrid with it's information when i click on a name in the datalist.
so after i have bounded the ADODC controls to there rightful places i have used this code for the click event for the datalist:
Code:
Private Sub DLBill_Click()
Dim strSQL As String
strSQL = "SELECT * FROM InformationT WHERE BillID = " & "'" & _
DLBill.BoundText & "'"
AdoGrid.RecordSource = strSQL
AdoGrid.Refresh
End Sub
lee123