CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Jul 2003
    Location
    Bali, Indonesia
    Posts
    103

    Question TextBox that cache the previous Text.

    I want to make text box control that cache the previous type Text in the text box.

    It's just like the Text box in Search Function that belongs to Windows OS.

    When I type something in that text box some Text that typed previously is appear drop downed.

    Please give me a starting point to do create a control like this.

    Thanks B4.

  2. #2
    Join Date
    Oct 2002
    Location
    Timisoara, Romania
    Posts
    14,360

    Re: TextBox that cache the previous Text.

    Well, first, you should have a list with the history (previous entered texts). Then you should also have a listbox to display it. Then you handle the KeyPress event for the textbox and display the listbox. I suppose that you want to filter it, so that you search the history list for everything that starts with the current text in Textbox and display only that in the listbox.
    Marius Bancila
    Home Page
    My CodeGuru articles

    I do not offer technical support via PM or e-mail. Please use vbBulletin codes.

  3. #3
    Join Date
    Jul 2003
    Location
    Bali, Indonesia
    Posts
    103

    Re: TextBox that cache the previous Text.

    Is there any link that explain about best approach for this problem??

  4. #4
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: TextBox that cache the previous Text.

    what's in the textbox? if you query some table, then you'd remember the values, or else, all possible values
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  5. #5
    Join Date
    Jul 2003
    Location
    Bali, Indonesia
    Posts
    103

    Re: TextBox that cache the previous Text.

    No database...

    It just a textBox that remember the previous Text that type in it...
    just like the textBox in Windows search...

  6. #6
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: TextBox that cache the previous Text.

    that remembers search terms. describe what you want, and give as many details as possible
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

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

Featured