Page 1 of 1

#RECORD_ID# not working in Default Filter for Browse

Posted: Thu May 12, 2016 10:26 pm
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?

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

Posted: Wed May 18, 2016 7:59 am
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

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

Posted: Wed May 18, 2016 4:40 pm
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.

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

Posted: Thu May 19, 2016 3:00 am
by admin
mlawton,

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


Steven

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

Posted: Thu May 19, 2016 2:52 pm
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?

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

Posted: Mon May 23, 2016 9:03 am
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.

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

Posted: Tue May 24, 2016 8:35 pm
by mlawton
Thanks David and Steven. I updated nuBuilder and now it works fine. Much appreciated.

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

Posted: Thu May 26, 2016 3:29 am
by admin
.