Hi Everybody,
I'm using VB to create a stand alone application.
I want to delete some data item from Combo box & List Box.
I've done this.
When I try to delete any data item from the combo or List box, its deleting.
But the problem is when I re-open the same application the deleted item is also displaying in the list box & combo box. But I don't want it to be like that.
How ever this application was not connected to Database.
The list present in the Combo box are added at the Design time.
Could anybody help me please....?
Thanks & regards,
Prem
13 4314
Its because you are not deleting the item from the source of list where list and combo boxes are populating, or from the code.
You need to use either filing or database or you can use windows registry to do this otherwise the way you are using is impossible to delete some item permanently. :)
Regards
ARUZ
What is the source of data for Combo box & List Box.
is that being populated from database ? or hard coded ?
if that the case you need to delete from database as well while deleting from the control.
if hard coded need to modify the code.
@debasisdas
I directly provided values to Listbox & Combo box @ design time. Not using code or Database. Because these boxes contains only few data items. (around 8 to 10).
ThanQ for showing interest sir.
Please reply me.
You are hardcoding the items. Save all items in a file and at runtime populate your control from that file...
@EYE4U
Yes, Please tell me how to save those items in a NOTEPAD file instead of MS Access & how to retreieve & delete those items.
Please help me..
If you dont know File systems it ll be better to use MSAccess instead of using files...
Whatever i ll upload an example...
Regards
ARUZ
@EYE4U
Yes, I was doing the same thing. Anyhow thanks for your kind co-operation.
& if you don't mind, will you please send a sample code for editing data present in DataGrid Control...? I am also using that Datagrid which is connected to Database, but I couldn't find how to edit.
I m sorry for replying late.... I was sick actually... :)
In the example i have used fso to save the list..
Regards
ARUZ
ThanQ So much Sir.
Please tell me how to edit data present in DataGrid control which is connected to Access table. Please.
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: anita |
last post by:
Hi All
Can anybody pls help me out with this problem.
I have a combo box control which has about 10,000 values in it. These
values in the combo box are called from a different table.
When i use a value(1 out of 10000) in the combo box for a particular
record say Record1, this value should no longer be displayed for the
next new record say Record2 and the combo box should just display only
9999 values. I am trying to do this, just...
|
by: Bob Darlington |
last post by:
Using Access 2002.
I have imported one form and two modules from another database, in order to
compare code.
Having finished the comparison, I cannot delete them.
When I press 'Delete', I get a message asking for confirmation 'Do you want
to permanently delete etc', I respond 'Yes' but the object remains. No error
message is generated.
If I try to open the object in design view, I get a message:
|
by: Jeremy Dillinger |
last post by:
I have a program setup to pull data from a database. My database table has
things such as (category, Item, price, etc.) In my program I want to have
multiple list boxes that will have a pull down list of different categories.
The category is stored as a number and the item is stored as a string. Also
once the item is picked from the list I would also like to extract the price
corresponding to the chosen item.
This program will be to...
|
by: Kay |
last post by:
Hi all,
Could you tell me the best way to add a blank item(as first item) in a data
binded combo box? Because I think I didn't do it right and it generate an
error if the second item(after the top blank item) is selected by using
Combo.SelectedValue :
"Specified argument was out of the range of valid values.
Parameter name: '-2147483648' is not a valid value for 'index'.
|
by: Evan |
last post by:
I have a data bound combo box. The combo box displays several items (status
code descriptions). After the combo box is bound, I want to set the combo box
so that the "Draft" status is displayed by default. Since the data originally
comes from a database I don't know which position in the combo box it will be
and I don't want to hardcode the status_code field (I want to select the
combo box item based upon status_desc).
...
| |
by: Bill |
last post by:
Problem:
Combo box data disappears from view when a requery is done
See "Background" below for details on tables, forms & controls
On a form, I want to use the setting of bound combo box C1 to limit
what is displayed in bound combo box C2. When I display Tbl-A records
on a continuous form, and navigate away from record 1 to record 2, the
previously entered data displayed in C2 for record 1 disappears from
|
by: rn5a |
last post by:
The .NET 2.0 documentation states the following:
When using a DataSet or DataTable in conjunction with a DataAdapter & a
relational data source, use the Delete method of the DataRow to remove
the row. The Delete method marks the row as Deleted in the DataSet or
DataTable but does not remove it. Instead when the DataAdapter
encounters a row marked as Deleted, it executes its DeleteCommand
method to delete the row at the data source. The...
|
by: jasone |
last post by:
Hi,
A section of my database allows users to delete items from a table, there is only one collumn in the table, this contains module information(parts of a manufacturing line) due to the lines regulary changing i added a section to delete modules. so far ive got the combo box which selects the modules from a table using a select query, when a specific module is selected i need it to be deleted.
the problem im having is when the delete...
|
by: Max |
last post by:
Hello,
I made a windows form with a combo box and 4 text boxes. All 5 objects should get their data from a data set which is populated
in the form load method. The combo box has item ids. When the users selects an item from the combo box I'd like the 4 text boxes to
get populated with the corresponding item information from the same dataset table row that the combo box is pulling it's info from.
Is there an easy way of doing this besides...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |