
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-14-2015 07:46 AM
Hi All,
I am having a problem with a Catalog form that has a multiple choice variable. The choices for the variable are coming from the pc_hardware_cat_item table and I have the following reference qualifier on it: javascript:wmc_filter_options()...this function looks like this:
function wmc_filter_options() {
var myTable = current.getTableName();
var string = "";
gs.addInfoMessage('Filtering the List ');
gs.addInfoMessage('myTable ' + myTable);
if (myTable == 'sc_cat_item') {
var printerColor = current.variables.newprt_color;
var printerType = current.variables.newprt_printerType;
gs.addInfoMessage('printerColor ' + printerColor);
string = "category=604e09e26069210055dd239fccf49a07^u_print_color=" + current.variables.newprt_color + "^u_printer_type=" + current.variables.newprt_printerType + "^u_ihis_print=" + current.variables.newprt_IHIS + "^u_prescription_print=" + current.variables.newprt_Prescriptions + "^u_sheet_count=" + current.variables.newprt_SheetsPrinted + "^u_user_number=" + current.variables.newprt_NumberUsers + "^u_double_sided_printing=" + current.variables.newprt_DoubleSided;
gs.addInfoMessage('string ' + string);
return string;
}
}
On the Catalog Item, I have the choice variables that are to be selected by the user and I am wanting the reference qualifier on the multiple choice variable to use the selected values but the problem is the reference qualifier is not using the variable values that are being selected, it is using the variables default values that they are initially set to upon loading of the form. I cannot query a table because the values have not been save to any table until it gets submitted, but I need to limit the choices that display for selection based upon questions that the user answers (variables on the form) I was trying to figure out how to control when the reference qualifier would execute and run the script? Does anyone know how I can get this to work? Please help if you can. If you need any additonal information, please ask.
Thanks,
Trena
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-21-2015 04:11 AM
Hi Lars,
I wasn't able to use radio buttons because it wouldn't allow me to add or remove options but a , I did end up using a Lookup Select Box and basically used a GlideAjax Function from Client Script to send the variable parameters to a server script include to load the values in an array and return the possible options back to the the Client as an array and did a g_form.addOption on the Lookup Select Box variable. This worked fine, although I did have to trade the look that I wanted, but the end results works great. Now if the Multiple Choice field could somehow function that way. I have other postings about the usagae of the GlideAjax that drove me to this solution, so you could probably search for that and see the details. *Search for Query Catalog Item Variable
Thanks,
Trena
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-21-2015 03:47 AM
Any luck with this?
I'm having the exact same challenge!
Thanks
Lars Bo Wassini

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-21-2015 04:11 AM
Hi Lars,
I wasn't able to use radio buttons because it wouldn't allow me to add or remove options but a , I did end up using a Lookup Select Box and basically used a GlideAjax Function from Client Script to send the variable parameters to a server script include to load the values in an array and return the possible options back to the the Client as an array and did a g_form.addOption on the Lookup Select Box variable. This worked fine, although I did have to trade the look that I wanted, but the end results works great. Now if the Multiple Choice field could somehow function that way. I have other postings about the usagae of the GlideAjax that drove me to this solution, so you could probably search for that and see the details. *Search for Query Catalog Item Variable
Thanks,
Trena