Magic Button - Open form to specific tab?

  • 0
  • 1
  • Question
  • Updated 2 days ago
  • In Progress
Hello. Is it possible via magic button to open a form to a specific tab therein (i.e. form tab, not browser tab)? Thanks!
Photo of Patrick Dunn

Patrick Dunn

  • 480 Points 250 badge 2x thumb

Posted 1 month ago

  • 0
  • 1
Photo of Kingsly SD Samuel

Kingsly SD Samuel

  • 998 Points 500 badge 2x thumb
There might be some easier solution available. Not sure whether this will be helpful, but this is what I did to find an alternate solution to this problem. 
I moved the information that I needed to show under a tab in a form of a project to a separate table and had it show up in the tab as an 'embedded report' from the other table. E.g., I have a tab called 'documents' in a project's form and it lists (rather, pulls an 'embedded report') all the documents uploaded to QB related to a project from a separate table called 'documents' within the QB application.
I created a button on my dashboard with a direct link to that report from the other table.
In essence, when you click on the button it doesn't take you to the tab, but takes you to the source from where the information is pulled to show up under the tab.
Hope I am making sense.
Photo of QuickBasePros (Laura Thacker)

QuickBasePros (Laura Thacker), Champion

  • 5,466 Points 5k badge 2x thumb
I have not found a way to do this; and I know you are not the first person to ask.

If, however, you choose not to use TABS, and instead use Section Headings; there is a way to anchor a text element in each Section of a Form and then be able to redirect to a Form and have the form place the view at that anchored section (see portion of this post after the ***).

There are probably other techniques; and these days I personally prefer the TAB form layout better than one long scrollable Form.

I also do not recommend building multiple-forms, and being able to navigate to a customized form, just to provide the user a one-less-click experience; as this is a lot more work for an Admin to maintain.

At the top of your Form Layout, insert a new row and select the form element Text.

Then, in your Text Item Properties text: box put:

<p id="top" style="display: block; position: relative; top: -120px; visibility: hidden;"></p>

<a href="#nameOfYourSection" class="Vibrant Primary" style="font-weight: bold">Button Label Name</a>

<a href="#DifferentSectionName" class="Vibrant Primary" style="font-weight: bold">Button Label Name</a>

Then create another Form Element of Text and place it directly underneath a Section Heading form element.  In the Text Item Properties text: box put:

<p id="nameOfYourSection" style="display: block; position: relative; top: -120px; visibility: hidden;"></p><a href="#top">^ Top</a>

You can place these throughout your form and have a corresponding button at the top of your form to easily navigate longer forms.  This was how I would do it before TABS came into the platform.

Remember to make sure the id is the exact same name as the href="# name value that you use at the top of the form (no spaces allowed).  i.e.  #contacts will have an id="contacts"

You can then put these anchors in your form and make the navigation easier for Users inside a form as well as append to a URL the #anchor point when redirecting.

To add an anchor point to the end of a redirect add the "#idNameHere" in your URL.

Example URL output:

Photo of Shannon


  • 34 Points
If you mouse over the tab you want to direct the user to and look at the link displayed in your status bar, you'll see a string at the end of the URL like #tab_t1
Append that string to the URL in your magic button and it will open the form with focus on the selected tab. 
@Shannon.  It would be amazing if your simple suggestion worked, but I could not get it to work.  Have you tested this?
Photo of Brad Lemke

Brad Lemke

  • 224 Points 100 badge 2x thumb

I've used a modified version of this how-to guide to create a 'Save Button' inside a form that modifies a couple of hidden fields, then saves all current changes, and then re-opens the form in a targeted tab.

My (Formula Rich Text) button code is as follows:

& "Modified.JS"
& [CBSc2]
& [CBSt - SKW]
& "Button Text"
& [CBE]

My variable codes are unchanged from the original, but listed as follows:
  • [CBSc2] - "));void(0);
  • [CBSt - SKW] - ' class='Vibrant Tall' style='font-size:14px; color:white; background:#6BBD57; white-space:nowrap;'>
  • [CBE] - </a>

On my Modified.JS page:

$("#_fid_11").attr("checked", true);
var nextTabLink=$("li.ui-tabs-selected").next("[style!='display:none']").children("a");
var noErrorDialog=$('#qbDialog').length==0;
if( noErrorDialog ){
$("#tab_t2_link a").click();
Photo of Brad Lemke

Brad Lemke

  • 224 Points 100 badge 2x thumb
My absolute favorite aspect of this method is that has the ability to edit more fields in a single button press than the typical API_editrecord formula URL - because it's all done by backend script.  Introducing this has allowed me to trim down the number of form rules present in my primary data-entry form, which increases performance on many of my companies' older workstations.

A couple drawbacks that I know of, at the moment: I have absolutely no idea how to set certain types of fields (User, in particular) using this method, nor am I aware of a method to modify the destination url (such as loading in Ifv=1).
Photo of Patrick Dunn

Patrick Dunn

  • 480 Points 250 badge 2x thumb
Thanks, all!!!