Refreshing form bound to a Sharepoint table (1 Viewer)

BiigJiim

Registered User.
Local time
Today, 00:15
Joined
Jun 7, 2012
Messages
101
Hi,

I have a continuous form (lets call it frmX) in Access 2019 which has a query recordsource which pulls records from a linked Sharepoint list. The form has a function which opens a 2nd unbound form frmY, from which the user can run a SQL statement which will update one or more existing records which are displayed on the main form. The vba code in the unbound form runs the SQL update statement, refreshes the main form frmX and closes frmY.

The problem I am having is if I use form.refresh, the records on frmX are NOT refreshed. (However, If I click the "Refresh All" button in the ribbon, the changes appear.)

If I use form.requery, the form refreshes and the changes are shown straightaway.

So basically, forms("frmX").Requery works, but forms("frmX").refresh does not. Just to stress, I am not adding any new records, so I cannot understand why Refresh does not work. I would prefer to use Refresh for the performance advantage (and to save using a Find Record method again to return back to the current record in frmX)

Any help is as always greatly appreciated! Thanks!
Jim
 

arnelgp

error reading drive A:
Local time
Today, 07:15
Joined
May 7, 2009
Messages
12,050
how about if you use Requery.
 

Minty

AWF VIP
Local time
Today, 00:15
Joined
Jul 26, 2013
Messages
8,186
Have you considered a recordset.requery rather than a form requery?
 

BiigJiim

Registered User.
Local time
Today, 00:15
Joined
Jun 7, 2012
Messages
101
Thanks for your replies. Requery works fine - I just don't understand why Refresh doesn't (as I am not adding new records.) Especially when the "Refresh All" ribbon command seems to work ok.

Is it some limitation of using linked Sharepoint tables?
 

Minty

AWF VIP
Local time
Today, 00:15
Joined
Jul 26, 2013
Messages
8,186
I would think so - they aren't handled in the same way as a normal linked table.
 

Users who are viewing this thread

Top Bottom