Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Passing in variable or parameter values into a HTML form

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Passing in variable or parameter values into a HTML form
 Login/Join
 
Silver Member
posted
I have a HTML form that has 4 parameter values that are populated in the form with drop down lists that are chained together.

I would like to set and then pass in different values for these 4 parameters based on the user. I have looked in the forum postings and I haven't been able to find anything.

I would like to do as much in App Studio tool as possible.

Can any one share any logic or code on how to do this?

I'm using App Studio in 8.2.01M.

Any help would be appreciated.

This message has been edited. Last edited by: FP Mod Chuck,


WF 8.2.01M, MF MVS 7.6.5
 
Posts: 29 | Location: Milwaukee, WI | Registered: September 10, 2008Report This Post
Expert
posted Hide Post
One way would be to perform an Ajax call in an "onInitialUpdate" function and then set the drop down list selected value to the value(s) returned.

This can be achieved within the "Embedded JavaScript" tab and, as you're on WF8.2.01 (per your other post), you can make use of jQuery - which is easier.

The question is, do you have JavaScript knowledge or not? If you do, then good. If not, then giving you example code wouldn't help you much because you might not understand what it does.

If you do not have jQuery knowledge (or JavaScript) then I would suggest that is your next step.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Gold member
posted Hide Post
Are you asking how to populate your variables on load, based on values passed in? If so, then this can be done by passing the amper variables from your URL to the page.

https://servername.com/portalname?country=JAPAN

Then in the Embedded JavaScript, code the following function. You'll also want to trigger this JS function on load in the tasks and animations panel. Take note of the control's unique identifier - in the example below it's edit1 but yours would be whatever your dropdown list name is.


  
function passURLValues(){
  // split up the url following the ? into an array of name=value pairs
  var qStringArray = parent.location.search.split("?");
  var j;


  // loop through the array of name=value pairs and look for "country"
  for (var i=0; i < qStringArray.length; i++)
  {
    // split up each name=value string into name and value
    j = qStringArray[i].split("=");


    // the parm of interest
    if (j[0].indexOf("country") >= 0 )
    {
        //decode value from url
        var parm = decodeURIComponent(j[1]) ;


        //edit box to be populated
        var edit1 = IbComposer_getComponentById('edit1') ;


        //populate edit1 with parm
        edit1.value = parm;
    }
  }
}



WebFOCUS 8.2.03
z/OS
 
Posts: 66 | Registered: May 20, 2013Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Passing in variable or parameter values into a HTML form

Copyright © 1996-2020 Information Builders