Skip to main content
Solved

How can I get the records from a data view that are display on a grid without reselecting the records?

  • January 27, 2023
  • 3 replies
  • 483 views
  • Translate All

darylbowman
Captain II
Forum|alt.badge.img+17

I’m dealing with a situation on Invoices and Memos entry screen where the Applications tab data is generated from an action, which means that the View.Select() does not return the data. How can I see the records without using View.Select()

Best answer by darylbowman

@Naveen Boga - View.Cache.Cached did not seem to be at all reliable.

@aaghaei - I needed to update a record rather than get the changed record.

I found Base.Adjustments.Select() DOES return the records after they had been loaded with Base.loadDocuments.Press(); 

 

I don’t quite understand what the .Select() method does, as I thought it re-selects from the database, but apparently not.

View original

3 replies

Naveen Boga
Captain II
Forum|alt.badge.img+20

Hi @darylbowman  Have you checked with View.Cache.Cached() ?

Translate

aaghaei
Captain II
Forum|alt.badge.img+11
  • Captain II
  • January 30, 2023

I’m not sure what objective you have but if you want to get the modified record from Cache, in addition to what Naveen suggested, you might want to try Locate method something like

ARRegister cached = (ARRegister)Base.ARDocument.Cache.Locate(ardoc);

This will get the modified record for the ardoc 

 

Translate

darylbowman
Captain II
Forum|alt.badge.img+17

@Naveen Boga - View.Cache.Cached did not seem to be at all reliable.

@aaghaei - I needed to update a record rather than get the changed record.

I found Base.Adjustments.Select() DOES return the records after they had been loaded with Base.loadDocuments.Press(); 

 

I don’t quite understand what the .Select() method does, as I thought it re-selects from the database, but apparently not.

Translate