Title: Message
A.D.
 
It looks like the only change needed was to refer to the textbox name for the primary key on the main form, instead of the field name, and it works.  Is that what you did?  In all my years of Access development, I hadn't ever come across a problem solved this way, but it looks like the link to the subform couldn't be made to the actual field, since until you leave a record, it isn't actually saved, and therefore the link was actually still to the previous record.  Thanks, that's a direction I hadn't thought to look (just wish you'd mentioned how you made the fix)!
 
Tobi
-----Original Message-----
From: AccessDevelopers@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of A.D.Tejpal
Sent: Wednesday, November 30, 2005 12:59 PM
To: AccessDevelopers@yahoogroups.com
Subject: Re: [AccessDevelopers] Keeping subform updated

Tobi,
 
    Modified file named ListSelection_Fixed.zip has been uploaded to the files section. You might like to try it out and confirm whether the problem stands resolved.
 
Best wishes,
A.D.Tejpal
 
----- Original Message -----
Sent: Wednesday, November 30, 2005 20:11
Subject: RE: [AccessDevelopers] Keeping subform updated

Because I think this could be a useful routine for many of us, not just for me, once it works correctly, I've whittled my DB down and put it up in the Files/Need Help With section -- ListSelection.zip, in Access 2002.  The purpose of this database is to track errors in medication distribution to youth in detention centers, and I want all the selections in the list to be visible so the data entry person can easily select one or more choices from the list.  The form frmOccurrences has the steps to make the error happen.  Thanks all!
 
Tobi
-----Original Message-----
From: AccessDevelopers@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of brij
Sent: Wednesday, November 30, 2005 12:36 AM
To: AccessDevelopers@yahoogroups.com
Subject: Re: [AccessDevelopers] Keeping subform updated

Hi Tobi
 
i read the query about "Keeping subform updated" but didnt get it.
do u have MDB file and if it is possible please attach (zip file) it to
get the extact problem.
 
thanks
 
Brij here.
----- Original Message -----
Sent: Tuesday, November 29, 2005 10:38 PM
Subject: [AccessDevelopers] Keeping subform updated

I have a data entry form with a subform on a tab control - the fact that it's on a tab may be irrelevant, but maybe not …  Instead of having dropdowns for the entries in the subform, I have a list box outside the subform, and want any entry clicked in the listbox to go into the subform, which I do in code, in the listbox OnClick event.  (This is to prevent duplicate entries in the subform.)  This works beautifully for the first record entered, but on the second entry, the subform comes up with the previous entry's selection, although the correct data is saved.  Now if I switch tabs (here's where it becomes relevant!), and come back to the tab with the subform, the selection process works fine.  I've been trying to assure that the record is saved before entering the subform data, but sometimes come up against the "You can't save the data at this time" message.

When this works right, it's elegant, but when it doesn't, it is downright frustrating!

Tobi Hoffman
Dept. of Youth Services
Boston, MA




Please zip all files prior to uploading to Files section.




SPONSORED LINKS
Microsoft access developer Microsoft access help Microsoft access database
Microsoft access training Microsoft access training course Microsoft access programming


YAHOO! GROUPS LINKS




Reply via email to