The CreatorCon Call for Content is officially open! Get started here.

Unable to open multiple sub tabs with g_aw.openRecord in workspace client script

Snehal13
Kilo Sage

I want to open multiple sub tabs in workspace client script.

I have a UI action that has a code in workspace client script to get the list collector values from form.  There is no issue in the param list. That part is verified. 

If there are 3 selections in the list collector, it should open 3 sub tabs

 

Snippet

 

 

for (var i=0; i<users_list.length; i++) {
          var user_query = '^first_name='+users_list[i];
          g_aw.openRecord("sys_user", "-1", {"query": user_query });
}

 

 

Looping it in for loop but only opens 1 sub tab. If 3 users selected on form, open 3 sub tabs on sys_user table.

 

Please help

 
 
13 REPLIES 13

@Snehal13 Here is my code.

function onClick(g_form) {
	for (var i=0; i<3; i++) {
          var user_query = '^first_name=anvesh';
          g_aw.openRecord("sys_user", "-1", {"query": user_query });
	}
}
Thanks,
Anvesh

I tried your code. opens only 1 tab.

I tried your code in PDI, only it opens 1 sub tab. How are you able to open multiple tabs with same code ?

@Snehal13  See the screenshots below, check if you are missing any other attributes.

AnveshKumarM_0-1695024207888.png

 

AnveshKumarM_1-1695024228582.png

 

AnveshKumarM_2-1695024254335.png

 

Thanks,
Anvesh

ALL is same. still 1 sub tab opens with the same code 😞