Filter on Form (1 Viewer)

ahmad_rmh

Member
Local time
Tomorrow, 02:48
Joined
Jun 26, 2022
Messages
243
I have applied filter on a form. The code is as under;

[Forms]![TransactionsMain].Form.Filter = "[TranTypeFK]=" & Me.TranTypeFK
[Forms]![TransactionsMain].Form.FilterOn = True

It goes to First Record of Filter but I want it on absolute position.

Kindly suggest
 

ahmad_rmh

Member
Local time
Tomorrow, 02:48
Joined
Jun 26, 2022
Messages
243
On load my forms open on new record, I have to make selection from the said Combobox for data entry and i have also applied filter on the same combobox.

I want as I select from combobox list it should have to stay on the current situation but it goes to first record.

I have attached snapshots from QuickBooks as it works like that.

Or we could say that On previous record click it should have to show only those records which was selected before in the combobox.
 

Attachments

  • Capture.GIF
    Capture.GIF
    78.8 KB · Views: 67
  • Capture1.GIF
    Capture1.GIF
    132.6 KB · Views: 69

jdraw

Super Moderator
Staff member
Local time
Today, 19:48
Joined
Jan 23, 2006
Messages
15,364
Please describe what you want to happen in simple English with no database jargon.
We don't know you nor your organization, so, just as you would tell someone who knows nothing of database, how would describe your current issue.
 

CJ_London

Super Moderator
Staff member
Local time
Today, 23:48
Joined
Feb 19, 2013
Messages
16,553
As jdraw says - you need to be clearer what you mean by 'absolute position'

Do you mean the last row - ready for new input?

And would be better to show your form rather than another app since it is not obvious from that
 

ahmad_rmh

Member
Local time
Tomorrow, 02:48
Joined
Jun 26, 2022
Messages
243
Scenario:
Combobox with list of accounts as shown in the picture.
For the data entry purpose you have to choose from the list.

Requirement:

As you will click on previous record button, It should have to go for those records as per the selection in the combo box.
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 07:48
Joined
May 7, 2009
Messages
19,169
is that MSA or Excel app?
 

CJ_London

Super Moderator
Staff member
Local time
Today, 23:48
Joined
Feb 19, 2013
Messages
16,553
As you will click on previous record button, It should have to go for those records as per the selection in the combo box.
the basic code would be

mycombo=whatever uniquely identifies the previous record

But if you want a complete answer then we need to know what the combo rowsource is so we can determine the order. So if the accounts are ordered alphabetically you would need to base your code on that - or perhaps they are ordered by some other field such as the account number which is not shown. And perhaps it is bound to an autonumber PK. And perhaps the data at the bottom is in a subform and is using the linkchild/master properties? or perhaps not?
 

Users who are viewing this thread

Top Bottom