Welcome to the nuBuilder Forums!

Register and log in to access exclusive forums and content available only to registered users.

#RECORD_ID# not working in Default Filter for Browse

Locked
mlawton
Posts: 16
Joined: Mon May 09, 2016 6:16 pm

#RECORD_ID# not working in Default Filter for Browse

Unread post by mlawton »

I cannot seem to pass the RECORD_ID of the current for to another form invoked by a button on the current form. If I use any of the fields on the form, they work, but RECORD_ID does not. I tried using #vendor_id#, which is the field name of the unique id (and should be the same value as #RECORD_ID#), but for it to work I need to ensure vendor_id is on the form that has the button, which is problematic because it is the primary key and gets updated twice (as mentioned in another post).

I read in some other posts that some others have experienced this problem. Has it been fixed, or am I doing something wrong?
admin
Site Admin
Posts: 2814
Joined: Mon Jun 15, 2009 2:23 am
Been thanked: 25 times

Re: #RECORD_ID# not working in Default Filter for Browse

Unread post by admin »

mlawton,

You need to explain where and when you are trying to use #RECORD_ID#. What event are you using eg.. is it on Before Save?

Steven
mlawton
Posts: 16
Joined: Mon May 09, 2016 6:16 pm

Re: #RECORD_ID# not working in Default Filter for Browse

Unread post by mlawton »

I am using #RECORD_ID# in the Default Filter for Browse option of a button I have created to go on a form. The #RECORD_ID# should resolve to be the vendor_id of the record I am displaying in this form, and I need to pass this vendor_id to the browse view of the form called via the button, to limit the records displayed in the called form to those for the vendor displayed in the calling form.
admin
Site Admin
Posts: 2814
Joined: Mon Jun 15, 2009 2:23 am
Been thanked: 25 times

Re: #RECORD_ID# not working in Default Filter for Browse

Unread post by admin »

mlawton,

Here it is working in the livedemo..
rec1.PNG
rec2.PNG
Attached is the sql for the live demo


Steven
You do not have the required permissions to view the files attached to this post.
mlawton
Posts: 16
Joined: Mon May 09, 2016 6:16 pm

Re: #RECORD_ID# not working in Default Filter for Browse

Unread post by mlawton »

Interesting. Your example is for a Browse object. I am using a Button object. I tested my form using a Browse object and it does indeed work as you've shown. But the Button does not. Can you try your example using a Button object to call the target form?
david
Posts: 4
Joined: Mon Jun 15, 2009 10:01 am

Re: #RECORD_ID# not working in Default Filter for Browse

Unread post by david »

Hi mlawton,

I did some tests and saw exactly what you were describing.
I have added a change to nuBuilder that should fix this. You can update nuBuilder or check out the github repository.
mlawton
Posts: 16
Joined: Mon May 09, 2016 6:16 pm

Re: #RECORD_ID# not working in Default Filter for Browse

Unread post by mlawton »

Thanks David and Steven. I updated nuBuilder and now it works fine. Much appreciated.
admin
Site Admin
Posts: 2814
Joined: Mon Jun 15, 2009 2:23 am
Been thanked: 25 times

Re: #RECORD_ID# not working in Default Filter for Browse

Unread post by admin »

.
Locked