design problem

krishnanhemanth

Registered User.
Local time
Today, 12:33
Joined
Jun 12, 2009
Messages
115
hi everybody

how to handle check box in a form where all textboxes are calculated
Let me explain
i have a form DELIVERY FORM in which i record material deliverd to customers on a day to day basis withrespect to a order no

i have another form called DELIVERY STATUS which shows all records pertaining to a order no.
In this form all the data come from the qry..there is no data entry
i have filedS QTY ORDERD and QTY DELIVERD
QTY ORDERD gets the value from the qry
QTY DELIVERD is a calculated field which sums all qty deliverd wrt order no
i Also have a check box called ORDER COMPLETE
I want this to be checked if QTY ORDERD = QTY DELIVERD
How can i triger this
what is the event required?

if me.qtyorderd = me.qtydeliverd then
me.ordercomplete = true
else
me.ordercomplete = false

the above code is not working for ... the following
form current
qtydeliverd after update

what could be wrong
please help
 
Looks like it should be working.... Check to make sure qtyorderd, qtydeliverd, and ordercomplete are actually the names of the textboxes and checkbox... No spaces in there? And post what the error message says if you are getting one.
 
thanks for the reply

it works only if...
the delivery status form is open. ( its executing at form current )

But....
what if i dont open the Delivery staus form

A scenario may be....
i enter data in DELIVERY FORM on a day to day basis

the ORDER COMPLETE check box is updated only if the delivery status form is open ( on form current )

if i have to generate a report on all ORDERS THAT ARE COMPLETE then
do i have to manually open the DELIVERY STATUS form and run through all records just to see that the ORDERCOMPLETE box is updated ???

or is there any other way around
 
Me always refers to the current form or report. Can this be the problem. Can you post your DB after compacting and zipping it?
 
It sounds like your textboxes are unbound. Are they? If so, whatever you do on the form is not going to be recorded in the table. Make sure your changes made on the form are reflected in the table... open it and look. Check the control source of the texbox and checkbox.
 
hi rabbie
thanks for your reply

iam sorry that iam not in a position to upload the db
 
hi curtis
thanks for your time

the calculated text boxes are unbound but the check box is bound to a table

the issue is that the checkbox status depends on the value of the unbound text box
 
Would be easier if you could see it....but, at this point I would move your calculation to the query... example... Field1: ([filedA]+[fieldB])
Then run your query with the form being open... see if any errors appear.
 
Last edited:

Users who are viewing this thread

Back
Top Bottom