473,385 Members | 1,848 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Fail To reset the combobox.text

My code is so simple to reset the text or set text to blank after the user
choose the value in combobox.

Private Sub cboBLData_SelectedIndexChanged(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
cboBLData.SelectedIndexChanged
Select Case UCase(Me.cboBLData.Text)
Case "CNTR&MARKING"
Dim frmCntrMark As New frmSeaCntrMarking()
frmCntrMark.pHBLNo = Me.txtHBLNo.Text
frmCntrMark.ShowDialog()

End Select
-> Me.cboBLData.ResetText()
-> Me.cboBLData.Text = ""
Both code are file to set the blank text.


Nov 20 '05 #1
2 3286
* "Agnes" <ag***@dynamictech.com.hk> scripsit:
My code is so simple to reset the text or set text to blank after the user
choose the value in combobox.

Private Sub cboBLData_SelectedIndexChanged(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
cboBLData.SelectedIndexChanged
Select Case UCase(Me.cboBLData.Text)
Case "CNTR&MARKING"
Dim frmCntrMark As New frmSeaCntrMarking()
frmCntrMark.pHBLNo = Me.txtHBLNo.Text
frmCntrMark.ShowDialog()

End Select
-> Me.cboBLData.ResetText()
-> Me.cboBLData.Text = ""
Both code are file to set the blank text.


Try to set the 'SelectedIndex' to -1 twice.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #2
What's the DropDownStyle Property set to?

--
Erik Porter
Microsoft MVP
Lead Software Architect
Aptera Software
"Agnes" wrote:
My code is so simple to reset the text or set text to blank after the user
choose the value in combobox.

Private Sub cboBLData_SelectedIndexChanged(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
cboBLData.SelectedIndexChanged
Select Case UCase(Me.cboBLData.Text)
Case "CNTR&MARKING"
Dim frmCntrMark As New frmSeaCntrMarking()
frmCntrMark.pHBLNo = Me.txtHBLNo.Text
frmCntrMark.ShowDialog()

End Select
-> Me.cboBLData.ResetText()
-> Me.cboBLData.Text = ""
Both code are file to set the blank text.


Nov 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

13
by: Mr. B | last post by:
Here's the situation... You've a combobox with Items already added. Say they look like this (or even lines of text): 10-00-232 10-00-256 10-01-006 10-01-213 10-02-200
3
by: PeterZ | last post by:
G'day, After doing much searching and pinching bits of ideas from here there and everywhere I came up with a fairly 'clean' solution of including a comboBox into a dataGrid column. You can...
3
by: TT (Tom Tempelaere) | last post by:
Hay there, I'm writing my own DataGridComboBoxColumn because .NET 1.1 does not have one (I hope .NET 2.0 supplies one). I based it on this article:...
6
by: Matt | last post by:
I'm not entirely sure how to describe this issue. I have a number of ComboBoxes in my application which have their text properties bound to a field in a data set. The items loaded in the ComboBox...
6
by: dbuchanan | last post by:
VS2005 I've been reading all the help I can on the topic (MSDN, other) but I can't make sense of this. Desired behavior; The user is to choose from the displayed list of the databound combobox...
0
by: Frnak McKenney | last post by:
Can I use a bound ComboBox for both browsing and editing? I'm working on a small, standalone database application using Visual C#.NET 2003 and an Access data file. In order to keep the number...
5
by: dbspang | last post by:
I am using VBA and trying to find the right language to reset a combo box so it is blank. After the user selects an item in the combobox, there is a button that adds that item to a form. The...
5
by: marshmallowww | last post by:
I have an Access 2000 mde application which uses ADO and pass through queries to communicate with SQL Server 7, 2000 or 2005. Some of my customers, especially those with SQL Server 2005, have had...
2
by: =?Utf-8?B?V29ua28gdGhlIFNhbmU=?= | last post by:
Hello, I have a ComboBox that has a DataContext set on it. When a PropertyChanged event is fired (based on a static instance of some class), I'd like to update the DataContext on the combo, but...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.