My database is simple. It has a table that tracks customers, with they're name, address, etc.
I have a price list table that contains "iteminstal l" , "price", and "qty"
and I have a payment table that trackes date, and payment amount.
I have a subform, with the field (textbox) "price." I have it auto populate when I type in something under (combobox) "iteminstal l". This is a recent addition. I used to have to type it manually.
In the subform, "iteminstal l" is a combo box, and price is a text box.
In the footer of the subform, I have the expression:
=Sum([price]*[qty]).
On the main form I have a text box that links to this field, to display a subtotal. Now the price is autopopulating in the subform, but it is not changing my subtotal. This only started happening when I set "price" to autopopulate. The existing subtotal is still there, but If I add anything to the order, it won't update the subtotal. Instead, it continues to display the old subtotal.
I added a new record, and tried entering some new data, but subtotal is outputing "0" on all new records. Any Ideas?
3 2022
Try updating the subtotal on the main form in iteminstall combobox's after update event, using the code shown below. Since the iteminstall combobox is on the subform, the following code should be placed with the subform code.
Private Sub itemInstall_Aft erUpdate()
Me.Parent.Subto tal.Recalc
End Sub
You need to replace the names I used for your combobox and subtotal control with the actual names if the actual names are different.
Try updating the subtotal on the main form in iteminstall combobox's after update event, using the code shown below. Since the iteminstall combobox is on the subform, the following code should be placed with the subform code.
Private Sub itemInstall_Aft erUpdate()
Me.Parent.Subto tal.Recalc
End Sub
You need to replace the names I used for your combobox and subtotal control with the actual names if the actual names are different.
OK, I TRIED THIS, AND GOT THE FOLLOWING MESSAGE:
RUN-TIME ERROR '438'
OBJECT DOESN'T SUPPORT THIS PROPERTY OR METHOD.
WHAT ELSE CAN I DO?
OK, I TRIED THIS, AND GOT THE FOLLOWING MESSAGE:
RUN-TIME ERROR '438'
OBJECT DOESN'T SUPPORT THIS PROPERTY OR METHOD.
WHAT ELSE CAN I DO?
Ok, try changing this: Me.Parent.Subto tal.Recalc
To This: Parent.Subtotal .Recalc
If that does not work, post back with the code exactly as you have it.
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Branko Collin |
last post by:
Hello,
The following is perhaps not directly a CSS problem, but it does seem to
involve Internet Explorer's stylesheet handling.
I tried Svend Tofte's solution for using expressions in stylesheets to
create a max-width effect. Very useful, but it does not work without
problems in IE 5.0 for Windows (or at all in IE 5.1 for Mac, but that may
have other causes).
|
by: Csaba Gabor |
last post by:
How, using javascript, can you set or change a CSS value
from something to something else which has the IE
proprietary format: expression(javasriptCode)?
I'd like to know the answer in general, but the specific
issue motivating this is that I have an image in a TD
which I am able to nicely align left/right/center/top
bottom/middle and set (stretch) to various sizes.
|
by: Rolan |
last post by:
I'm using Access 97 and need some assistance in sorting out a proper
DSum expression, or maybe even DCount might be an alternative. I have
tried numerous combinations, but with no apparent success.
The DSum function relates to a subform (sfrmCost) with a text box
(RefCost) which is intended to be the container for a total from a
query (qryItems). The query has three number columns from the table
(tblItems) of which I have an expression...
|
by: gretchen.ogrady |
last post by:
I admit - I'm a simple user but looking to improve skills.
Instructions aren't helping and have searched this group but am getting
bogged down by some of the programming-speak.
I have a query called PAL_PA Summary and in that query I calculate
several fields, all %s: Fed, ITS, SALT which are 3 of the 6 columns for
example. Basically its a query by person that shows the % of their time
spent in these diff fields (they add up to 100%).
...
|
by: hungrymind |
last post by:
Hi all,
I am developing some control (textbox based), to validate inputs to
that control I am using regular expression, where pattern is generated
dynamically. I need to identify what all charcters are allowed with
that particular pattern. Is this possible or any way to solve this. Or
else, i want to identify if only one character is allowed then that
character will apear & user need not to enter any value for that.
Please suggest if...
| |
by: frankh |
last post by:
Got earlier very valuable feedback from this group, so I am trying
again.
Given a string with an arithmetic expression containing variables, e.g.
"a+b*sin(x)", how can I calculate its value within my program for given
variable values? (Think of the string as a user input.) Is there an
easier way than writing an interpreter myself? Mathematical notation is
preferred, but C# syntax ("Sin" instead of "sin") would be acceptable
too.
|
by: mark |
last post by:
In the sample code for Programming Microsoft Visual Basic.NET by Francesco
Balena (Microsoft Press) there is a program (ExprEvaluator) that evaluates
expressions. It has a bug in that when the expression evaluates to a near
zero value(i.e. one that the system expresses in scientific notation), a
system error occurs.
For example sin(3.1415927) or 1-0.999999
I would like to use the fundamentals in a broader application where I will
need...
|
by: Vishnu Kumar Tiwari |
last post by:
I am using below expression in xsd...
I am getting devide by zero error.
For ur information I am filling the dataset with the results obtained from
Stored procedure.
Now again I need to calculate one field which is the divison of two fields
returned from SP.
Please notice that the third field is not available in the database. We need
to calculate inside xsd using the two fields returned from SP.
Please help
|
by: deanoooo812 |
last post by:
I have an Access query (written in MS Access 2000 - thats all we've got - don't get me started on that topic...) for making pharmacy dispensing labels based on an extract from an automated dispensing machine extract.
In this query, I use an expression to calculate the total tablet requirement from a combination of the table value of Sum of DailyQty * DaysSupply.
DaysSupply is a parameter that is entered by the user when running the query....
|
by: dspfun |
last post by:
Hi!
The words "expression" and "statement" are often used in C99 and C-
textbooks, however, I am not sure of the clear defintion of these
words with respect to C.
Can somebody provide a sharp defintion of "expression" and
"statement"? What is the difference between an expression and a
statement?
|
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: 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...
|
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: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
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 we have to send another system
| |