Skip to main content
Question

Copy Master Detail URL Button Question


I am looking for assistance with a formula URL button to copy master details from a template record id. I can make the button work when I input the specific number of the sourceRID, but I want to be able to base the sourceRID on a variable template id. Is there a way to make this work? See below.

"javascript:void(copyMasterDetailButtonHandler('&relfids=41&recurse=false&sourceRID=[Variable Record ID]\n\n\n&destrid=[Variable Template Record ID]" & [Record ID#] & "', 'bm8s38rgt'))"

I'd also love the ability to have the button land me on another form where I have the parent record with this button on an embedded report. Is this possible?



------------------------------
Luke Furuto
------------------------------
This topic has been closed for replies.

MarkShnierYou
Forum|alt.badge.img+24
It can be done with this API https://help.quickbase.com/api-guide/API_CopyMasterDetail.html
I'm tied up now on a backlog of work, but contact me directly if you need one on one assistance,

The syntax will be 

var text URL = (the copy master detail api);
var text DisplayParent  = URLRoot() & "db/" & [_DBID of the Parent table] & "?a=dr&rid=" & [Related Parent];

$URL
& "&rdr=&URLEncode($DisplayParent)

Give the API a try and post back if you get stuck.

------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------

Hi Luke, maybe it's too late to answer you, however, maybe someone could be use it.

If you have a field in your form and your source id its depending it you can use something like that: "javascript:void(copyMasterDetailButtonHandler('&relfids=41&recurse=false&sourceRID="& [Variable Record ID] & "&destrid=[Variable Template Record ID]" & [Record ID#] & "', 'bm8s38rgt'))"

Regards


------------------------------
David Parra
------------------------------