dbTalk Databases Forums  

Access Saving New Record Requery Refresh Issue

comp.databases.ms-access comp.databases.ms-access


Discuss Access Saving New Record Requery Refresh Issue in the comp.databases.ms-access forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
codemonkey
 
Posts: n/a

Default Access Saving New Record Requery Refresh Issue - 08-04-2003 , 06:57 PM






To anyone and all gurus:
Any help would be GREATLY appreciated! Thanks in advance

Application background:
Multi-user environment, split access database, access ver 9.0x
Developing the Access frontend on Win 2000, clients are running
Win 98.

Problem:
I have a form that has a Subform/Subreport that has it's
RecordSource bound to a query. When a new record is saved the SubForm
is supposed to reflect the new record added and display it, but it
doesn't. The second problem is when I can get the new record to show
up in the list, when I select it it doesn't become the 'live' record
for editing on the main form. I have tried refreshing, requerying etc
and still have no luck. Has anyone had a similar issue when selecting
a newly created record or could someone with more experience give me
some advice on tackling this one?

Wes

Reply With Quote
  #2  
Old   
TonyR
 
Posts: n/a

Default Re: Access Saving New Record Requery Refresh Issue - 08-05-2003 , 09:39 AM






You can force a subform control to be refreshed by reminding it of its
sourceobject name thus:-

Me!SubformControl.SourceObject="<Subform Name>"

or, if you don't know the name of the subform

Me!SubformControl.SourceObject=Me!SubformControl.S ourceObject


Tony R.

Reply With Quote
  #3  
Old   
codemonkey
 
Posts: n/a

Default Re: Access Saving New Record Requery Refresh Issue - 08-05-2003 , 09:54 AM



"TC" <a@b.c.d> wrote

Quote:
"codemonkey" <wesley_snipes1 (AT) hotmail (DOT) com> wrote in message
news:354c0df4.0308041557.49327324 (AT) posting (DOT) google.com...

How, and from which form, are you saving the new record?
I have a main form which has a tab control in which contain the
other Subforms/Subreports controls exist.

Quote:
When you say 5that the new record shows up "in the list", do you mean "in
the subform"? If so, you would not normally use a subform to display the
records available on the main form. You would use a combo box or listbox on
the *main* form, for that purpose. You use a subform to show other records
that are related to the record on the main form; eg. invoice lines of the
invoice header showing on the main form.
Yes, the 'list' is the returned records from a Query that the
Subform is bound. I have started looking into using a ComboBox instead
of the Subform control but I have discovered that using a ComboBox
only allows one field in a db table to be displayed or monitored (or
am I wrong?). If I go with using the ComboBox, is there a way to
display the results of a Query that retrieves a 5 field set of records
off an access db table? Thanks for your reply!!


Reply With Quote
  #4  
Old   
codemonkey
 
Posts: n/a

Default Re: Access Saving New Record Requery Refresh Issue - 08-05-2003 , 12:54 PM



Thanks for the help you guys!

After taking Tony R's advice I have gotten the Subform to refresh
after a New record is added. By the way, the New Record is added on
another Form which is viewed after clicking a Tab on the Tab Control
(positioned on this Main Form).
After this Subform refreshes now it displays the 'Newly Added' record
in the Subform 'list' but when I select it, it doesn't display it as
being the current 'live' record on the Main Form for editing. I can't
figure out why.

This problem has started as a result of another user within the
company creating a New Record and after saving the record, it is added
to a 'queue' (the Subform list) for another user to select and do his
work with, but when that user selects the record on the Subform, it
doesn't actually 'select', all other older records can be selected in
the Subform though. Problem seems to only be with Newly created
records. The only work around we have found is to close the frontend
and reload, then all Subform Records (including the New ones) can be
selected. Has anyone seen this issue before?

A Continuing Thanks in Advance!

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.