Results 1 to 1 of 1

Thread: "Cannot create a child list for field..."

  1. #1
    pryspr01 is offline VB.NET Forum Newbie
    .NET Framework
    .NET 1.1 (VS 2003)
    Join Date
    Jan 2006
    Posts
    15
    Reputation
    107

    "Cannot create a child list for field..."

    Getting this error, "Cannot create a child list for field FULLNAME" dont understand why. Can anyone see what's wrong? Let me know if I need to say more information about the sql DB.
    Code:
        Private Sub frmprospect_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    
            sspanelSearch.Visible = False
            btnprevious.Visible = False
            btnnext.Visible = False
    
            OleDbDataAdapter1.Fill(DataSet12)
            cbAutoComplete.DataSource = DataSet12.ProspectTable
            cbAutoComplete.DisplayMember = "FullName"
            cbAutoComplete.ValueMember = "FullName"
    
            Try
                Me.OleDbDataAdapter1.SelectCommand.CommandText = "SELECT * FROM ProspectTable"
                Me.OleDbDataAdapter1.Fill(DataSet12)
    
                Me.BindingContext(DataSet12, "FullName").AddNew()
                Me.BindingContext(DataSet12, "FullName").Position = Me.BindingContext(DataSet12, "FullName").Count - 1
                Me.cbAutoComplete.Text = ((Me.BindingContext(DataSet12, "FullName.ID").Current).ToString)
    
            Catch ex As Exception
                MsgBox(ex.Message)
            End Try
    
        End Sub
    Code:
        Private Sub MenuItem3_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem3.Click
            Dim newRow As DataRow '= DataSet12.FullName.NewRow
            Me.OleDbConnection.Open()
    
            newRow("FullName") = cbAutoComplete.Text
            DataSet12.Clear()
            DataSet12.Tables("LastName").Rows.Add(newRow)
    
            Me.OleDbDataAdapter1.Update(DataSet12)
            Me.OleDbConnection.Close()
        End Sub
    Last edited by pryspr01; 01-30-2006 at 11:04 AM.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Harvest time tracking