473,770 Members | 1,779 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

If a field is keyed in, then delete other fields

Hi

I have a textbox (Final Flat) that contains a default value of zero. The
other 2 textboxes (Final rate and Final Minimum) always have a numeric value
in them. What i want to do is this......whene ver the (Final Flat) is keyed
in, then delete the values in the Final Rate and Final Minimum........ ...how
would i go about doing this?......than k you!
--
Message posted via AccessMonster.c om
http://www.accessmonster.com/Uwe/For...ccess/200509/1
Nov 13 '05 #1
2 1356
James G wrote
I have a textbox (Final Flat) that contains
a default value of zero. The other 2 text-
boxes (Final rate and Final Minimum) always
have a numeric value in them. What i
want to do is this......whene ver the (Final
Flat) is keyed in, then delete the values
in the Final Rate and Final Minimum


Assuming the Control is bound to a Field in the RecordSource, in the
AfterUpdate event, put code to test for non-zero and to set the other
Controls to zero. If it is unbound, probably the Lost Focus event would be
best.

Larry Linson
Microsoft Access MVP
Nov 13 '05 #2
Ok .....this works great.....thank you!....but what if i want to reverse the
process. For instance, what if the person didn't like what they keyed in on
the (Final Flat) and wanted to basically undo what they just did, so the
original values, which were in the (final rate) and (final min) textboxes
before, show up again. How would i go about doin that? thank you!
--
Message posted via http://www.accessmonster.com
Nov 13 '05 #3

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

Similar topics

6
1852
by: Xah Lee | last post by:
© # -*- coding: utf-8 -*- © © # in Python, there's a special type of © # data structure called keyed list. it © # is a unordered list of pairs, each © # consists of a key and a value. It is © # also known as dictionary. © © # define a keyed list © aa = {'john':3, 'mary':4, 'jane':5, 'vicky':7}
4
1917
by: R Bolling | last post by:
Hi, I have a table where two fields will make up the primary key. In a few cases the second field will be blank. When I try to append the existing data into the keyed table I get the message that it cannot append a null value into the keyed field. Is there any way to set this up to allow the nulls in that second field? Thanks for any assistnace with this.
1
3447
by: Don Leverton | last post by:
Hi Folks, I have been given a CD with approx 130 .xls files (bean-counters!) that I would like to import and merge to ONE table (tblTradeshow). The XL files are *similarly*, but not identically structured, and the first row does NOT contain field names. Some (actually most) of the column names *are* the same in all of the spreadsheets.
18
18419
by: Dixie | last post by:
Can I set the Format property in a date/time field in code? Can I set the Input Mask in a date/time field in code? Can I set the Format of a Yes/No field to Checkbox in code? I am working on a remote update of tables and fields and can't find enough information on these things. Also, how do you index a field in code?
2
1315
by: MLH | last post by:
In design view, say you habitually type descriptions for each of the table fields you create. After many moons, many many tables and many many many fields - you wanna delete each and every table field description. Can that be done somehow using the tables collection and the fields collection??? Any resource you care to point out will be greatly appreciated.
1
3784
by: Harry Devine | last post by:
I have a DataGrid that is configured to use the Edit/Update/Cancel concept correctly. My grid shows values from 5 database fields. I only need to update that last 4 fields. The last field is a Yes/No value in Access. Using the OleDbCommand, if I do not consider the Yes/No field, the ExecuteNonQuery command, using my UPDATE SQL statement, updates the record correctly. However, if I put the Yes/No field into the mix, ExecuteNonQuery...
2
1568
by: develguy | last post by:
I am having trouble figuring this one out... Hopefully someone can help! I have a table ("tbl1") It has five (5) fields: 1- "Item1" 2- "Item2" 3- "Item3" 4- "ScanImage" (stores scan path/filename)
4
1752
by: lesperancer | last post by:
I've got a comboBox with 2 choices and based on the choice, I make button A or button B visible if choose choice 1, button A is visible now, I undo the choice so that the comboBox is null, but button A is still visible I tried the field's onChange event, but no luck I could use the form's timer event, but I wonder if there's a better
21
2914
by: no1zson | last post by:
I do not even know how to correctly ask this question. I have an item field in the code I am about to post. Simple intger meant to be an item number for a cd. The user enters this number. Over the last week I have played with Add buttons, Del buttons, Modify and everything else and it brought to light a problem I want to address today. I have always just used 1 for the first item, 2 for the second and so on ... well after I am done will all...
0
9617
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, 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...
0
10257
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, 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...
0
10099
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10037
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8931
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, 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...
1
7456
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 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...
0
6710
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();...
2
3609
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2849
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.