473,508 Members | 2,330 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Clearing listindex value

71 New Member
I've got a form set up that has a series of textboxes to enter employee info, with a listbox at the bottom listing all the employees with their title (to make it easier to find employees to edit information).

I'm having a problem though - if I click around on the listbox to view some employee records, then want to add a new employee, when I click on the add record button it edits the last employee I looked at with the new information. I've added a clear form box, to clear all the textboxes, so that the user can enter info, but it still places the new record over an existing record (the last record looked at with the list box).

Is there a way for me to clear the listindex value (or reset the listbox all together) so that when I enter new info, and click add employee it doesn't overwrite the old employee?
Jul 31 '07 #1
2 5287
rsteph
71 New Member
Any thoughts on this?
Aug 2 '07 #2
JKing
1,206 Recognized Expert Top Contributor
Whats the code behind your add new record button? Am I correct in assuming that you're using a search method under the afterupdate of the list box?
Aug 2 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
2060
by: Pavan Jha | last post by:
Hi, I am using File Input for one of my pages. I have multiple inputs on my page as <INPUT Type=FILE Name=File1> <INPUT Type=FILE Name=File2> and so on... I have a function for validating...
1
4224
by: hortoristic | last post by:
We are using JavaScript to Enable/Disable certain fields on web pages based on business rules. A simple example is if when using an option type tag, and the two options are Yes and No. If YES...
0
1495
by: Josh Nikle | last post by:
I just realized that I posted this earlier with no title. Sorry. Here's the original post: I have a form with a combo box on it that, when a selection is made, fills in several other controls...
1
1736
by: WEM | last post by:
I filling a combo box with all 50 states and when I select a customer from a list box I want to find the identity(listindex) in the combo box which is the identity stored in the customer record. If...
1
8386
by: andrew.panin | last post by:
Hi there! I've got a trouble with these things. What's going on? 1ST STEP: we have ListBox item. Let's call it ListBox1. We're adding four values to it using AddItem method:...
1
1736
by: Vayse | last post by:
I have a databound form, frmClients. One of the field is a combo box, comDepartment, which lets a user select a department for the Client. But I can't figure out how to clear the box. That is,...
3
2592
by: juengelj | last post by:
I need a little advice here... Option Compare Database Global ind As integer Private Sub someobject_on click() ind = 5 End Sub
10
42839
by: Ken OHanlon | last post by:
I have read everything I can find on the internet, BUT it doesn't help! I'm using Windows XP and Access 2003. The following code does increment the listindex as wanted but then after coming back...
4
12109
by: juing | last post by:
Hi All, I am very new in the VBA coding and I've noticed this (to me strange) behavior: Assume this code for "Value Items" type of single select two column ListBox: 1) If List98.ListIndex...
0
7233
marktang
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,...
0
7135
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...
0
7342
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
7505
tracyyun
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...
0
5650
agi2029
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,...
1
5060
isladogs
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...
0
4729
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...
0
3201
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1570
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.