11-17-2011 06:11 PM
Select (multiple) with arrow-button to other text area. 2008.3
Many apps, including newScale reporting, use multi-select boxes, with an arrow-button pointing to an identical box, that moves the selected items to the other text area. When finished - what has not been selected is on the left, and what has been selected on is the right. Has anyone used this in a service? Can it be done without writing tons of code? Thanks.
11-17-2011 06:11 PM
Thanks Chris, I appreciate it. I'll give it a try and see how it goes. It would be nice if this type of select box was native to nS. Another nice out-of-the-box feature would be a "processing" message/graphic (like the famous hourglass). We have a lot of services that go out to get data which can take some time.
11-17-2011 06:11 PM
This is the only way that I've found to add items to a select box at runtime.
var myaddressselect=document.getElementById('CMN_Physical_Location.Address');
myaddressselect.options.length = 0;
myaddressselect.add(new Option(" -- Select Address --", " -- Select Address --"))
myaddressselect.add(new Option(AddressName, AddressName));
You have to specify the DictionaryName.FieldName in your getElementById call.
Clear the select box by setting the options.length equal to 0.
11-17-2011 06:11 PM
I've only done the piece with copying what they selected (comma delimited list) to a different text area. I just did on onChange Conditional Rule with a setValue.
11-17-2011 06:11 PM
An enhancement request was opened for this feature a few days ago. The ID # is: 26952
11-17-2011 06:11 PM
I agree with the out of box feature, but if you wanted you could always either add code to display a prompt until the processing is complete, or as you describe change the mouse pointer to an hourglass(only visual).
//Set Cursor to hourglass
document.body.style.cursor = "wait" ;
//Set hourglass off
document.body.style.cursor = "default";
11-17-2011 06:11 PM
You can create the options for a drop-down list using a data retrieval rule. If you don't actually want to retrieve the rule contents from a database table, just write the rule like:
(Oracle)
Select 'Value 1' FieldName from dual
union
Select 'Value 2' from dual
...
(SQLServer)
Select 'Value 1' AS FieldName
union
select 'Value 2'
...
Just remember to put in the column alias ("FieldName") and map that column to a form field.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide