Select item on selectlist
Hi
I have a select list on APEX and select list has list of values definiton
select PROCNAME display_value, ID return_value
from PROCEDURES
order by 1When I select one of item I must call the a procedure that I have. How can I do ?
Edited by: esra aktas on 10.May.2011 00:14
It might also be possible that what you choose in your select list is not yet known. You could try to use &P2_SP. instead of :P2_SP but I don't think that will work.
Hmm seems you've hit a little bump and you will have to submit your page onchange of your select box and use a page process...
So remove the dynamic action and edit P2_SP. Under Settings - 'Page Action when Value Changed' choose submit page...
Create a page process and make it conditional with request = P2_SP
That's the easiest way, alternatives are using application on demand processes, but for now this will work ;)
Br,
Nico
Edited by: NicoMartens_InterAccessBE on 10-mei-2011 16:58
Similar Messages
-
Could not find selected item in LOV
hi i follow this sample http://www.scribd.com/doc/2633296/ADF-Learning-6-Dependent-List-Boxes ,but when i select my LOV am geting this error FacesCtrlListBinding> <getInputValue> ADFv: Could not find selected item matching value 100 of type: oracle.jbo.domain.Number in the list-of-values.
am in jdeveloper 11.1.1.6.0the data type am selecting is number but displaying employee name my page is,the value 100 is the employeeid is in db
<?xml version='1.0' encoding='UTF-8'?>
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
<jsp:directive.page contentType="text/html;charset=UTF-8"/>
<f:view>
<af:document id="d1">
<af:messages id="m1"/>
<af:form id="f1">
<af:panelHeader text="panelHeader 1" id="ph1">
<f:facet name="context"/>
<f:facet name="menuBar"/>
<f:facet name="toolbar">
<af:commandButton actionListener="#{bindings.CreateInsert.execute}"
text="CreateInsert"
id="cb1"/>
</f:facet>
<f:facet name="legend"/>
<f:facet name="info"/>
<af:panelFormLayout id="pfl1">
<af:inputText value="#{bindings.DepartmentId.inputValue}"
label="#{bindings.DepartmentId.hints.label}"
required="#{bindings.DepartmentId.hints.mandatory}"
columns="#{bindings.DepartmentId.hints.displayWidth}"
maximumLength="#{bindings.DepartmentId.hints.precision}"
shortDesc="#{bindings.DepartmentId.hints.tooltip}"
id="it1" rendered="false">
<f:validator binding="#{bindings.DepartmentId.validator}"/>
<af:convertNumber groupingUsed="false"
pattern="#{bindings.DepartmentId.format}"/>
</af:inputText>
<af:inputText value="#{bindings.EmployeeId.inputValue}"
label="#{bindings.EmployeeId.hints.label}"
required="#{bindings.EmployeeId.hints.mandatory}"
columns="#{bindings.EmployeeId.hints.displayWidth}"
maximumLength="#{bindings.EmployeeId.hints.precision}"
shortDesc="#{bindings.EmployeeId.hints.tooltip}"
id="it3" rendered="false">
<f:validator binding="#{bindings.EmployeeId.validator}"/>
<af:convertNumber groupingUsed="false"
pattern="#{bindings.EmployeeId.format}"/>
</af:inputText>
<af:inputText value="#{bindings.Password.inputValue}"
label="#{bindings.Password.hints.label}"
required="#{bindings.Password.hints.mandatory}"
columns="#{bindings.Password.hints.displayWidth}"
maximumLength="#{bindings.Password.hints.precision}"
shortDesc="#{bindings.Password.hints.tooltip}"
id="it4">
<f:validator binding="#{bindings.Password.validator}"/>
</af:inputText>
<af:inputText value="#{bindings.UserId.inputValue}"
label="#{bindings.UserId.hints.label}"
required="#{bindings.UserId.hints.mandatory}"
columns="#{bindings.UserId.hints.displayWidth}"
maximumLength="#{bindings.UserId.hints.precision}"
shortDesc="#{bindings.UserId.hints.tooltip}" id="it2">
<f:validator binding="#{bindings.UserId.validator}"/>
</af:inputText>
<af:selectOneChoice value="#{bindings.DepartmentId1.inputValue}"
label="#{bindings.DepartmentId1.label}"
required="#{bindings.DepartmentId1.hints.mandatory}"
shortDesc="#{bindings.DepartmentId1.hints.tooltip}"
id="soc1" autoSubmit="true">
<f:selectItems value="#{bindings.DepartmentId1.items}" id="si1"/>
</af:selectOneChoice>
<af:selectOneChoice value="#{bindings.EmployeeId1.inputValue}"
label="#{bindings.EmployeeId1.label}"
required="#{bindings.EmployeeId1.hints.mandatory}"
shortDesc="#{bindings.EmployeeId1.hints.tooltip}"
id="soc2" partialTriggers="soc1">
<f:selectItems value="#{bindings.EmployeeId1.items}" id="si2"/>
</af:selectOneChoice>
</af:panelFormLayout>
</af:panelHeader>
</af:form>
</af:document>
</f:view>
</jsp:root>my view is
<?xml version="1.0" encoding="windows-1252" ?>
<!DOCTYPE ViewObject SYSTEM "jbo_03_01.dtd">
<!---->
<ViewObject
xmlns="http://xmlns.oracle.com/bc4j"
Name="VikUserViewObj"
Version="11.1.1.61.92"
InheritPersonalization="true"
SelectList="VikUser.DEPARTMENT_ID,
VikUser.EMPLOYEE_ID,
VikUser.PASSWORD,
VikUser.USER_ID"
FromList="VIKUSER VikUser"
BindingStyle="OracleName"
CustomQuery="false"
PageIterMode="Full"
UseGlueCode="false">
<Properties>
<SchemaBasedProperties>
<LABEL
ResId="model.VikUserViewObj_LABEL"/>
</SchemaBasedProperties>
</Properties>
<EntityUsage
Name="VikUser"
Entity="model.VikUser"/>
<ViewAttribute
Name="DepartmentId"
IsNotNull="true"
PrecisionRule="true"
EntityAttrName="DepartmentId"
EntityUsage="VikUser"
AliasName="DEPARTMENT_ID"/>
<ViewAttribute
Name="EmployeeId"
IsNotNull="true"
PrecisionRule="true"
EntityAttrName="EmployeeId"
EntityUsage="VikUser"
AliasName="EMPLOYEE_ID"/>
<ViewAttribute
Name="Password"
PrecisionRule="true"
EntityAttrName="Password"
EntityUsage="VikUser"
AliasName="PASSWORD"/>
<ViewAttribute
Name="UserId"
PrecisionRule="true"
EntityAttrName="UserId"
EntityUsage="VikUser"
AliasName="USER_ID"/>
<ResourceBundle>
<PropertiesBundle
PropertiesFile="model.ModelBundle"/>
</ResourceBundle>
</ViewObject>Edited by: user0994 on 2012/10/20 9:07 PM
Edited by: user0994 on 2012/10/20 9:29 PM
Edited by: user0994 on 2012/10/20 10:41 PM -
Using checkboxes to select items in a Spark DataGroup/List?
I have a DataGroup from Catalyst, laid out like a tile list:
I'd like to do something a bit different, in that I'd like to allow people to multi-select items in the list using those checkboxes instead of the usual command/control-click.
The checkbox, label and image are in the itemRenderer. Is there an easy way that I can have that checkbox toggle the selected state of its list item?Hi,
Using the checkbox as a selection is easy enough as all you have to do is add a change event to the checkbox in the renderer and then in the event
selected=mycheckbox.selected;
The fun is how to handle the list click event from the checkbox you can stop propagation but if the item is clicked it will reset the selected indices.
There is a few ways to handle this
when processing the list don't use the selected indices just use the checkbox value to determine whats selected
disable the listbox click event so items have to be selected with the checkbox
or the most complex lots of overriding so that click acts like a ctrl/click and the checkbox/itemclick can toggle each other.
David -
Combox Box not displaying selected item
Below is the code I'm using to try to capture and display the
selected item from a ComboBox:
private function
changeProjectTypeSelection(event:Event):void{
projectTypeChange.text+=event.currentTarget.selectedItem.cboProjectType
+ " " +
event.currentTarget.selectedIndex + "\n";
Then the ComboBox:
<mx:ComboBox fontSize="12" x="93" y="83" width="110"
id="cboProjectType" dataProvider="{projectTypeArray}"
labelField="projectTypeName" selectedIndex="0"
click="changeProjectTypeSelection(event)"></mx:ComboBox>
Then the TextInput:
<mx:TextInput id="projectTypeChange" x="248.95" y="84"
width="121"/>
I know there's something wrong with the Actionscript code...
just haven't figured it out. Any suggestions would be greatly
appreciated!I've almost got it...
private function
changeProjectTypeSelection(event:Event):void{
var i:int;
for(i=0;i<projectTypeArray.length;i++){
if(projectTypeArray.getItemAt(i).projectTypeName ==
event.currentTarget.selectedItem.projectTypeName){
projectTypeChange.text+=projectTypeArray.getItemAt(i).projectTypeName
+ "\n";
Alert.show(projectTypeArray.getItemAt(i).projectTypeName +
"FirstAlert");
//Alert.show(event.currentTarget.selectedItem.projectTypeName +
"SecondAlert");
I just can't seem to be able to reset the value in the
textInput field. I've tried setting it equal to spaces in several
places, but it won't change after the first selection. Any ideas?
Thanks for any suggestions! -
Getting selected item from combobox itemrenderer and storing in object
Hi Guys,
Can anyone help me in this regard. Its very urgent.
I have a combo box itemrenderer in datagrid column. I want to get the user selected item from the dropdown of the row(s) (User may select values from combo box from multiple rows of datagrid) and corressponding values of all other columns of the rows and store it in an object . Then pass this object to database to update only those rows that user has changed.
I am able to get the selected item from combo box using "event.currentTarget.selectedItem" and corressponding values of all other columns of the rows using "valueSelect.ID", etc where valueSelect is object which contains data for datagrid. But am stuck up with, how to store the selected item value of the combobox and corressponding values of all other columns of the rows into an Object ?.
Can anybody help me with sample to store selected item from combobox and its corressponding values of all other columns into an object which i can send to db...?
Kindly help me in this regard.
Thanks,
Anand.Hi!
Are you using a collection of VO or DTO as the dataprovider of the combobox component?
If so, have you created some attribute there to control the user's selection in the combobox?
For instance:
private var selected:Boolean = false;
If your solution fits this approach, you may create a new collection that contains just the objects that were selected by the user, it means you can loop through the datagrid's dataprovider and only insert in this new collection those objects that have the attribute "selected" set to true.
For instance:
private function getSelectedRecords(datagridDataProvider:ArrayCollection):ArrayCollection
var newCollection:ArrayCollection = new ArrayCollection();
for each (var item:Object in datagridDataProvider)
if (item.selected)
newCollection.addItem(item)
return newCollection;
Afterwards, you may serialize this new collection with your back-end.
Hope it helps you!
Cheers,
@Pablo_Souza -
Get Selected Items from ListBox
Hi,
How do I get the Selected items of a List in Flex.
I am using a multi-select List.
ThxNever mind..I got it.
it as simple as that:
Alert.show (lst.selectedItem.fieldname);
;) -
Removing selected items from listbox
Hi ADF Experts,
I have a selectmanylistbox with few values displaying in UI and a Remove Button at the bottom.
User selects certain items from the listbox and clicks on Remove button. The selected items should be reomved. Can anybody suggest how to do this.
Thanks,
AnimeshDuplicate of https://forums.oracle.com/thread/2562542
User, please don't ask the same question multiple times. If you don't get the answer you want it may be because you did not give the right information and or use case me understand.
Timo -
How to get the selected items from listbox
Regarding listbox i have two questions
1) I want to get the selected items as per the order in which ihave selected.Presently i'm getting in the ascending order.For example after selcting the 1,2,6 if i select 3 then its giving 1,2,3,6.But i want it in the order 1,2,6,3
2)I want to select items from a single list box to many other listboxes.(ie) my first selection should goto first,second one to the second listbox and like this.How should i write the logic.
please give me a suggestion.In order to have the selected items line up in accordance to the selection order, please do it one at a time. (That's the limit for that VI)
If you need more than that (i.e. to regconize which item clicked first and which one comes later), you may have to figure it out ya
Wish you good luck. Perhaps, someone else has a already made vi.
Cheers!
ian.f
Ian F
Since LabVIEW 5.1... 7.1.1... 2009, 2010
依恩与LabVIEW
LVVILIB.blogspot.com -
How to find total size of selected items in library
My library contains much more than my 2GB Nano can hold. I frequently change the content of the Nano with songs and books. How can I keep track of the total size of items I'm selecting for the next Nano update to speed my update? Presently I can only guess what to unselect if the selections are of greater size than my Nano will hold.
There is no direct way to accumulate total file size when selecting a subset of songs within the Library or a Playlist.
The only way you can manage this is to create an empty Playlist that you can drag songs into. It will accumulate the total size of the songs as you deposit them into it (as described by StarDeb above).
If you get to a size greater than the nano will hold, then remove one or more songs from that Playlist.
There is no 'running-total' of only the selected items like Windows Explorer does. Sorry. -
No selectable items exist for purchase requisition l_banfn
Hi,
While creating PO with ref to PR getting the below error :
no selectable items exist for purchase requisition l'banf .
Checked if the PO is created, its not created,.
checked if the item is blocked/cancelled/deleted. Nothing is set.
PR looks fine. Dont know if any authorization data is missing?Check the status tab in ME53N whether all the qty in PR are already used up
Or
Check the line item in PR whether it is deleted
Edited by: Karthik on Jul 20, 2011 12:37 PM -
How to create a report based on selected item from Select list?
Hi,
I have created a tables_LOV based on:
select table_name d, table_name r from user_tab_cols
where column_name like '%_type%'
Then I created a page item ListOfTables, Display as select list and pointing to tables_LOV.
I run the page, and i can select the table i want from the drop down list.
How to create a report based on the selected item? (ex: select * from selected_table)
many thanks in advance
SalahHi Salah,
Allright, have a look at this page: http://apex.oracle.com/pls/apex/f?p=vincentdeelen:collection_report
I think that simulates what you're trying to accomplish. I've set up the simplest method I could think of.
The report is based on an apex collection. If you are not familiar with that, you should study the documentation: APEX_COLLECTION
To recreate my example you should:
1) create an (interactive) report on your collection
SELECT *
FROM APEX_collections
WHERE collection_name = 'MY_COLLECTION'
2) create a page_item select list for the tables you want to display (in my case this is called "P38_TABLES" )
3) create a dynamic action that triggers on change of your select list page_item. The dynamic action must be a PL/SQL procedure perfoming the following code:
declare
l_query varchar2(4000);
begin
l_query := 'select * from '||:P38_TABLES;
if apex_collection.collection_exists
( p_collection_name => 'MY_COLLECTION' )
then
apex_collection.delete_collection
( p_collection_name => 'MY_COLLECTION' );
end if;
apex_collection.create_collection_from_query
( p_collection_name => 'MY_COLLECTION'
, p_query => l_query
end;
Make sure you add your page_item to the "Page Items to Submit" section.
4) Add an extra true action that does a refresh of the report region.
Here are two pictures describing the da:
http://www.vincentdeelen.com/images/otn/OTN_COLLECTION_REPORT_DA1.png
http://www.vincentdeelen.com/images/otn/OTN_COLLECTION_REPORT_DA2.png
Good luck and regards,
Vincent
http://vincentdeelen.blogspot.com -
How i can set the selected item of a dropDown component from java code
Hi
Thank you for reading my post
How i can set the slected item of a DropDown component from backing beans java code ?
it is binded with a database , so one field determine its display and one other field determine its value , I want to set the selected item of this combobox
In back code i have both value and display values to use them .
can some one give me some help ?
Thanks ,See code sample 3 at http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/helloweb.html
See also, the selection components row in the table under http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/helloweb.html
It says
One way to preselect items is to call setSelectedValue(Object[]) or setSelectedValue(Object) from the prerender() method. You pass in the return values of the items that you want preselected. Be sure to verify that getSelected() returns null before setting the default options, or you will overwrite the user's selections on a post-back. -
How to disable a lead selected item in a radio button group ?
Hi,
I have a radio button group and there are entries to create radio buttons dynamically. means there is only one radio button group in the UI design and in runtime I will be having two radio buttons (For ex: Yes and No ) . Now If I want to disable either Yes or No radio button, I am unable to do so. because If I disable the radio button group it disables both. So, I can have lead selected item for ex: Yes which I want to disable. I want to know specifically how this Yes button to be disabled by taking lead selected index item.
Please help.
Thanks
PraveenTry setting the radio button value of the lead selected button to abap_false/space.
-
How can a classic report be filtered using one select item and dynamic action?
APEX 4.2.1
DB 11g
I have a page with 4 reports on it. The top report is an interactive report and the following 3 are classic reports. The users would like to be able to use a select list to filter the 3rd report by PO line number without refreshing the entire page.
After verifying that the report is set to allow partial refreshes, I took the following steps
1. Created a PO Line select item (p_po_line_select) in the same report region
2. Added p_po_line_select to the report query
3. Created a dynamic action on p_po_line_select with 2 true actions
1. Set value (p_po_line_select)
2. Refresh report region.
The Set Value dynamic step was not working; I would get an out of memory error at line 2, memory stack error, or the value did not get saved to session state depending on the settings I selected. I was able to get it working with the following set:
1. Action = Set Value
2. Set type = PL/SQL Expression
3. PL/SQL Expression = :p_field_does_not_exist
4. Page items to submit = blank
5. Selection Type = Item(s)
6. Item(s) = p_field_does_not_exist
p_field_does_not_exist does not exist as a page or application item which leads me to believe that this is a bug and I am just lucky that it worked. I would rather know how to do this properly. Can someone please provide a link to a working example of how this should be done or state which settings are wrong?
I was able to reproduce the issue in the following app
http://apex.oracle.com/pls/apex/f?p=4500:1000
workspace = occam
user test/apex1
Thanks,STOP POSTING DUPLICATE THREADS.
If you have additional information, continue the discussion by posting it as a follow-up on the original thread: What is the proper way to filter classic report using just an LOV select field with dynamic action? -
Bug (possibly?): SelectManyShuttle fails to display selected items
Bug (possibly?): SelectManyShuttle fails to display selected items when valuePassThru="true" in ADF 10g
Hello all,
When run, the example below shows a Select Many Shuttle with four choices in the leading list. When items are shuttled to the training list and the page is submitted the trailing list is rendered with no items selected. Is this a bug?
Configuration
This example was constructed using jDeveloper 10.1.3.5.0.
A new application was created using the Web Application [JSF, ADF BC] template although no business components are used.
Steps to Reproduce
1. Create the following backing bean class.
package com.fmcna.adf.test.view;
import java.util.ArrayList;
import java.util.List;
import javax.faces.model.SelectItem;
public class ShuttleBean {
public ShuttleBean() {
private List availableItems;
private List selectedItems;
public void setAvailableItems(List availableItems) {
this.availableItems = availableItems;
public List getAvailableItems() {
//populate with a List of SelectItem instances on the inital call to this method
if(this.availableItems==null) {
this.availableItems=generateSelectItemsList();
return availableItems;
public void setSelectedItems(List selectedItems) {
this.selectedItems = selectedItems;
public List getSelectedItems() {
return selectedItems;
* Build a List of SelectItem instances to be used by an af:selectManyShuttle
* @return A List containing SelectItems instances
private List generateSelectItemsList() {
List initialItems = new ArrayList();
initialItems.add(new SelectItem(new Integer(11),"First Choice"));
initialItems.add(new SelectItem(new Integer(22),"Second Choice"));
initialItems.add(new SelectItem(new Integer(33),"Third Choice"));
initialItems.add(new SelectItem(new Integer(44),"Fourth Choice"));
return initialItems;
}2. Configure the ShuttleBean class as a session scoped managed bean as in the following faces-config.xml file.
<?xml version="1.0" encoding="windows-1252"?>
<!DOCTYPE faces-config PUBLIC
"-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
"http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
<faces-config xmlns="http://java.sun.com/JSF/Configuration">
<managed-bean>
<managed-bean-name>ShuttleBean</managed-bean-name>
<managed-bean-class>com.fmcna.adf.test.view.ShuttleBean</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>
</managed-bean>
<application>
<default-render-kit-id>oracle.adf.core</default-render-kit-id>
</application>
</faces-config>3. Create a JSP page containing an af:selectManyShuttle with a nested f:selectItems component. Wire the values for these components to the properties in the managed bean.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ page contentType="text/html;charset=windows-1252"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://xmlns.oracle.com/adf/faces" prefix="af"%>
<f:view>
<html>
<head>
<meta http-equiv="Content-Type"
content="text/html; charset=windows-1252"/>
<title>testShuttle</title>
</head>
<body><h:form>
<af:selectManyShuttle value="#{ShuttleBean.selectedItems}" valuePassThru="true">
<f:selectItems value="#{ShuttleBean.availableItems}"/>
</af:selectManyShuttle>
<af:commandLink text="Postback"/>
</h:form></body>
</html>
</f:view>4. Run the JSP. Validate that the trailing list is initially empty.
5. Shuttle one or more items to the trailing list and click the Postback button. Validate that when the page refreshes the trailing list is again empty.
Thanks for any input you might be able to provide.
Chris Mihalcik
Edited by: user5384858 on Jun 14, 2010 1:06 PMI'm holding my Nano in my hot little hands with ALL of the things you listed, but here's the sad, simple truth: you CAN'T use iTunes to sync everything. It works well for:
1) Music
2) Videos (except sometimes in Vista)
3) Photos (as long as they're not too large)
but is terrible for:
1) calendar
2) contacts
3) To-Do lists
For the latter use something like "iGadget" (www.ipodsoft.com). I also edit/store notes w/iGadget plus it allows you to export files, etc.
I gave up on syncing iTunes w/Outlook long ago. Good luck.
Maybe you are looking for
-
ORACLE NETWORK MANAGER 기본적인 사용방법
제품 : SQL*NET 작성날짜 : 2002-04-12 ORACLE NETWORK MANAGER 기본적인 사용방법 ======================================== I. TERMINOLOGY TO KNOW BEFORE USING THIS GUIDE A. community - a set of nodes that use the same network protocol. B. listener - a service that wai
-
I recently set up my Apple TV 3 in my college dorm, which uses a WPA2 Enterprise network, to airplay from my 2011 MBP on 10.8.2. It was working fine (Airplay, mirroring, home sharing), then all of a sudden Airplay and Mirroring stopped working. The i
-
Export for iPhone & iPad same time - Without resolution issues?
Hello, I have developed an app for the iPhone and it runs perfectly fine on the iOS for iPhone. I am trying to port it to the iPad so I have done the proper stage adjustments and have set export as "iPhone & iPad" It opens up fine on my iPad, but the
-
GR blocked Quantity and corresponding released quantity
Hi, I want to find out GR blocked Quantity and corresponding GR released quantity (103 & its 105), kindly let me know the table link to get these data. Thanks, Kaleel
-
Every time I try to load itunes, it just runs for a few secconds, freezes
Gateway PC Windows XP