cancel
Showing results for 
Search instead for 
Did you mean: 
Workflow Hero

Setting Option Buttons in a choice field rendered as buttons

I have a form, I'd like to setup as tabbed viewing. I have the "Choice" control setup to render as buttons and a javascript variable name of "TabRules".

I want to use a button control, that when it's pressed it goes to the next tab. Presumably, by setting a javascript function that sets it? 

I'm using the following code. 

NWF$('#' + TabRules).find('input:radio[value="Start"]').attr("checked","true");

(Start is one of the values of the choice buttons.) 

What am I missing? Thanks in advance. 

Reply
7 Replies
Workflow Hero

Re: Setting Option Buttons in a choice field rendered as buttons

Hi ‌,

Have you already checked this Nintex Xchange source?

Cheers,

Rick

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Setting Option Buttons in a choice field rendered as buttons

Try using this

NWF$('#' + TabRules).attr('checked', true);

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Setting Option Buttons in a choice field rendered as buttons

Hi Rick.  Yes. I can setup the tab browsing. What i'd like is to have a button at the bottom of the form that says something like, "Save and continue", that will then, using javascript, "change the tab".  (By selecting an item in the choice list.) 

Does that make sense?  

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Setting Option Buttons in a choice field rendered as buttons

Thank you, Sojan. How would the code above show it what "tab" to move to? 

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Setting Option Buttons in a choice field rendered as buttons

‌,

Could you provide some screenshots to possibly show what you're trying to achieve?

From what I gather, you have it where you can click any of the tabs up top and that portion of the form will show and now you want it if they click a save or next type button, it will move from say, tab1 to tab2?

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Setting Option Buttons in a choice field rendered as buttons

You can set a value to a text box control to hold the position of your tab. On button click you can set a value using the have script.

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Setting Option Buttons in a choice field rendered as buttons

This is what I used.  It clicks the button, which changes everything associated with it in one go:

var objRequestType =NWF$('#' + varRequestType);

objRequestType.find('input:radio[value="'+strCurrentTabName+'"]').click();

"varRequestType" is the ClientID variable set to the Choice control ('render as buttons' selected inside the control).

"strCurrentTabName" is just text of the item I wish to click.

Thanks,

~~Kolten

Accept as Solution Reply