[RESOLVED] Autocomplete TextBox
Hi
I've got a basic email application set up, and I'd like the "To" field (TextBox1) to be an autocomplete textbox.
I'd also like the user to be able to edit what their contacts are, and so be able to add named to the autocomplete suggestions.
I can get TextBox1's autocomplete suggestion to come from TextBox2's current Text - however this means I can only have one name as a suggested contact.
Ideally, something like a list box would be ideal, so the user can add and remove names, and this list would then provide the source for the autocomplete.
Thanks for the help,
M
1 Attachment(s)
Re: [RESOLVED] Autocomplete TextBox
One thing i forgot to mention was if you wanted to save your contacts. revised a little but would suggest using a ListView.
Re: [RESOLVED] Autocomplete TextBox
That is even better! Thank you for being so willing and helpful :D
Re: [RESOLVED] Autocomplete TextBox
Hi, sorry to bother again...
i've just about got your second load of code into my own project...however, one build error occurring:
"GetItemText is not a member of System.Windows.Forms.Listview"...
Cannot work out what I've not done right?
Thanks again for your continued help! I appreciate it loads. :)
Re: [RESOLVED] Autocomplete TextBox
(the line appears just before the very end of the code)
Re: [RESOLVED] Autocomplete TextBox
My project uploaded is using a listbox, you are using a list view.
Code:
For Each contact As ListViewItem In Me.lvwMyListView.Items
MessageBox.Show(contact.Text)
Next
So replace MessageBox with sw.writeline(contact.text)
Re: [RESOLVED] Autocomplete TextBox
Thanks for your prompt reply and apologies for mine taking ages!
Can you clarify where that new code should go?
I'm using the project you uploaded which was designed for saving contacts, and am getting the "GetItemText is not a member of System.Windows.Forms.Listview"... error.
And when I swap in the
vb Code:
For Each contact As ListViewItem In Me.lvwMyListView.Items
MessageBox.Show(contact.Text)
Next
where I think it should be, it means the form no longer works.
Apologies for the hassle,
Thanks for your help
Re: [RESOLVED] Autocomplete TextBox
Apologies! have just sorted it
Thanks again!