Wrox Home  
Search P2P Archive for: Go

  Return to Index  

pro_vb thread: DataList Control


Message #1 by "Indra" <indra_sct@h...> on Tue, 9 Apr 2002 07:11:16 +0700
This is a multi-part message in MIME format.

------=_NextPart_000_0064_01C1DF95.BD989860
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


  Hi, how can I bind this ADODC2 to a DataList control ?
  I've set the DataList1.RowSource property to ADODC2 at design time but
  an error occured "[ADODC]: no RecordSource specified. [ADO]:Command
  text was not set for the command object"

  Here is the code :
  Private Sub ADODC1_MoveComplete(ByVal adReason As 
ADODB.EventReasonEnum,
  ByVal pError As ADODB.Error, adStatus As ADODB.EventStatusEnum, ByVal
  pRecordset As ADODB.Recordset)
      ADODC2.RecordSource =3D _
          "select Author from authors, " & _
          "[Title Author] where authors.au_id=3D" & _
          "[Title Author].au_id and " & _
          "[Title Author].ISBN=3D'" & _
          "ADODC1.recordset.Fields(""ISBN"")" & " '"
      ADODC2.Refresh
  End Sub

  Thanks in advance,




  Return to Index