Results 1 to 5 of 5

Thread: Who can fix this ?[Resolved]

  1. #1

    Thread Starter
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083

    Who can fix this ?[Resolved]

    I got this working (yes the same code , not the same proj ) two weeks ago . I dunno what's wrong today ? I'm searching database to list the result in a listbox but they are showing as dataview items . f u c k , I'm using exactly the same CODE .

    Last edited by Pirate; May 19th, 2003 at 03:46 PM.

  2. #2
    Your Ad Here! Edneeis's Avatar
    Join Date
    Feb 2000
    Location
    Moreno Valley, CA (SoCal)
    Posts
    7,339
    DisplayMember is Case Sensitive, change:

    s.SearchDB(TextBox1.Text, "mytab", "c_appname", ListBox1)

    To:

    s.SearchDB(TextBox1.Text, "mytab", "C_AppName", ListBox1)

    Then everything works fine.

  3. #3
    Your Ad Here! Edneeis's Avatar
    Join Date
    Feb 2000
    Location
    Moreno Valley, CA (SoCal)
    Posts
    7,339
    Also in regards to using:

    MsgBox(ListBox1.SelectedItem.ToString)

    This will still return DataRowView because the value or text of a field isn't specificied as the ToString return. You can use either of the following, but I would suggest the first:

    MsgBox(ListBox1.Text)

    Or:

    MsgBox(DirectCast(ListBox1.SelectedItem, DataRowView).Item(ListBox1.DisplayMember).ToString)

  4. #4

    Thread Starter
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    Yes , it seems case sensitive . Thank you Edneeis . You're real Guru .

    MsgBox(ListBox1.SelectedItem.ToString)

    this line popups the msgbox multiple times , what's wrong ?

  5. #5

    Thread Starter
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    Never mind buddy , I won't do it this way .

Posting Permissions

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



Click Here to Expand Forum to Full Width