How to assign the class value dynamically in jsp:useBean ?its urgent
Hi
I want to set the class value of <jsp:useBean> dynamically
when i am trying to this way
<jsp:useBean id="<%=id %>" class="<%=beanclass %>" scope="request">
<jsp:setProperty name="<%=id %>" property="*"/>
</jsp:useBean>
where beanclass is .class file that is to be used by the usebean tag
i am getting following error
The value for the useBean class attribute <%=beanclass %> is invalid.
please help as soon as possible
regards,
Rameshwari
You can not do that.The jsp:useBean and jsp:setProperty are action tags and not custom tags. Action tags get translated into Java code in the translation unit and are then compiled. Custom tag are backed by classes and the tag get translated into a method call of the class.
Similar Messages
-
How to assign the two values for constant (same key)
How to assign the two values for constant (same key)
CONSTANTS: c_pstkey TYPE bschl VALUE '09',
c_splgl TYPE umskz VALUE 'I',
c_buzei TYPE buzei VALUE '001'.
using BSCH1 again i have two asign vaue
can you just let me know
Edited by: sravya_se38 on Nov 23, 2010 12:14 AMYou can create a structure for that constant .
You can define in this way
CONSTANTS : BEGIN OF c_pstkey,
01 TYPE bschl VALUE '01',
02 TYPE bschl VALUE '02',
END OF c_pstkey.
and can access using...
c_pstkey-01, c_pstkey-02 ........ -
How to assign the trip type to a particular employee. - Urgent
Hi,
In HR - Module - Travel Management.
I am trying to create a travel request for an employee.
i am getting the error message :
Statutory trip type does not exist in the system (T702G)
how to assign the trip type to a particular employee.
regards
Giri
*Points will be assigned for all the valid answers.Hi Fred,
If you open any activities or opportunities, you can see the description if you select new button and click on the process type. It will be display Activities and below that New: Activity. Instead of always displaying the same description I want to override the description according to the process type. For me the application is not activity but Incident. Hope I am clear with the question.
Thanks,
Anu -
How to assign the default value to search parameter
Hi Experts,
I am using search view , In this I have 5 parameter lets say Transaction Type, Partner No. etc... Now I want to assign a default value to transaction type ( lets say TA) . User should be able to see this default value in the transaction type field before pressing search button.
How can I do it?
My second problem is: I have configured this search view using configuration tool but I want to assign only one value to transaction type (i.e. user should not be able to add new row in the search criteria for the transaction type by using + sign) but in rest 4 fields he can add new row and search based on that.
Note: I am using only "Is" criteria .
Any pointer will be helpful for me
Thanks and regards,
SandeepHi Sandeep,
For the default search values, here is a solution. You have to redefine the method GET_VALUE1 of the context node
For example if it is the BP search (component BP_HEAD_SEARCH) context node is your enhanced class: ZL_BP_HEAD__MAINSEARCH_CN00
METHOD get_value1.
CALL METHOD super->get_value1
EXPORTING
attribute_path = attribute_path
iterator = iterator
RECEIVING
value = value.
TRY.
* Delegate operation to selection parameter
DATA: current TYPE REF TO if_bol_bo_property_access.
IF iterator IS BOUND.
current = iterator->get_current( ).
ELSE.
current = me->parameter_collection->get_current( ).
ENDIF.
IF current->get_property_as_string( iv_attr_name = 'ATTR_NAME' ) EQ 'XXX'.
IF value IS INITIAL.
value = 'Your default value'.
ENDIF.
ENDIF.
CATCH cx_root.
ENDTRY.
ENDMETHOD.
where XXX is the name of the field.
Default value will then appear in your search field, but you are still able to modify it if you want...
Regards,
Fabian -
How to set the charset encoding dynamically in JSP
Is there any way to set the charset encoding dynamically in a JSP
page?
we are using weblogic 6.1 on HP unix.
is there some way we can set the charset dynamically in the page directive
<%@ page contentType="text/html;charset=Shift_JIS" %>
and in MAET tag
<meta http-equiv="Content-Type" content="text/html" charset="Shift_JIS">
Saurabh AgarwalDear Saurabh,
I guess it is possible. Here is an example I have made some time ago :
In my html page :
<form name="form1" METHOD=POST Action=Lang ENCTYPE="application/x-www-form-urlencoded" >
<p>
<select name="code" size="1">
<option value="big5">Chinese</option>
<option value="ISO-2022-KR">Korean</option>
<option value="x-euc-jp">Japanese</option>
<option value="ISO-8859-1">Spanish</option>
<option value="ISO-8859-5">Russian</option>
<option value="ISO-8859-7">Greek</option>
<option value="ISO-8859-6">Arabic</option>
<option value="ISO-8859-9">French</option>
<option value="ISO-8559-1">German</option>
<option value="ISO-8859-4">Swedish</option>
<option value="ISO-8859-8">Hebrew</option>
<option value="ISO-8859-9">Turkish</option>
</select>
</p>
<p>
<textarea name="entree_text"></textarea>
<input type="submit" name="Submit" value="Submit" >
</p></form>
and in my jsp :
// Must set the content type first
res.setContentType("text/html");
code = req.getParameter("code");
example = req.getParameter("entree_text");
PrintWriter out = res.getWriter();
// The Servlet send to the Browser the informations to format the language type
out.println("<html><head><title>Hello World!</title><meta http-equiv=\"Content-Type\" content=\"text/html; charset="+code+"\"></head>");
// System recover the general Character encoding
String reqchar = req.getCharacterEncoding();
out.println("<body><h1>Hello MultiLingual World!</h1>");
out.println("You have defined an ISO of : "+code);
out.println("<BR>This is the code of the page that is displayed in this page<BR>");
out.println("<BR>");
out.println("<BR>");
out.println("Character encoding of the page is : "+reqchar);
out.println("<BR>This is the character code in the Servlet");
out.println("<BR>");
out.println("<BR>");
out.println("<BR>");
out.println("You have typed : "+example);
out.println("<BR>");
out.println("");
out.println("</body></html>");
I think starting from this example it is surely easy to modify dynamically the jsp.
The other possibility would be to use the Weblogic Commerce and the LOCALIZE function, so that you'll have an automatic redirection to the right jsp-encoding depending on the customer's language.
Feel free to reply on the forum for any related issue.
Best regards
Nohmenn BABAI
BEA EMEA Technical Support Engineer
"Saurabh" <[email protected]> a écrit dans le message de news: [email protected]...
Is there any way to set the charset encoding dynamically in a JSP
page?
we are using weblogic 6.1 on HP unix.
is there some way we can set the charset dynamically in the page directive
<%@ page contentType="text/html;charset=Shift_JIS" %>
and in MAET tag
<meta http-equiv="Content-Type" content="text/html" charset="Shift_JIS">
Saurabh Agarwal[att1.html] -
How to retrieve the parameter names from a JSP page ? Urgent Please
Hello,
Can anybody tell me how to retrieve the parameter names from the JSP
page. (without using getParameterNames() method.)
The problem with the getParameterNames() method is I get the Jumbled output.
I need it very badly
With regards
Ananth R
email:[email protected]
[email protected]Dear duffymo,
My primary intention is to convert the JSP form information into a XML file.
If I do not get the Parameter names in the correct order how can I maintain
tag order in XML file.
For ex: (JSP PAGE VIEW)
Name--
FirstName
MiddleName
LastName
Address--
Street1
Street2
City
Country
&so on
(XML File to be generated)
<Name>
<FirstName>Value</FirstName>
</Name>
<Address>
<street1>value</street1>
</Address>
& so on
If I use getParameterNames() to get all the parameter names(Which form the tag names in the XML file ) the Enumeration object it returns will not be in the same order as the text fields in JSP.From this I can not construct a meaningful XML file.
order means: Order of entry on the page, from top to bottom
That's it
Waiting for your responses -
How to assign the parameter value in form2 while passing it from form1
Hi
I have two forms,form1 is calling form2 passing a parameter client_id. If for that client_id form2 has any record it is displaying fine but if there is no record for the passing client_id , form2 could not get assigned to that client_id automatically. I want to get that parameter value in form2 so that I can add a new record (detail table). Please help!!
SumitaIn your servlet you can read directly the file using request.getInputStream().
In this way you get the InputStream of the file selected by the user.
I hope this help you. -
How to assign the result value of a sql stmt to a variable in sql*plus
e.g.
var v_date
var v_test :=select hour from tablename where date=v_datebut this piece of code doesn't work:
var in_year number
var start_date varchar2(30)
var mar_2nd_sun date
accept in_year number prompt 'Enter the year of interest>'
execute :start_date := '01-mar-' || &&in_year
print start_date
select next_day(:start_date,'sunday')+7 into :mar_2nd_sun from dual;
print mar_2nd_sun
delete from &&table_name where tdate=:mar_2nd_sun and hour=1;
Error:
old 1: delete from &&table_name where tdate=:mar_2nd_sun and hour=1
new 1: delete from tbl_datehour_test where tdate=:mar_2nd_sun and hour=1
SP2-0552: Bind variable "MAR_2ND_SUN" not declared. -
How to assign a class to the material through ABAP code
Hi,
I am working on a transaction in ABAP which takes material name, material description and a class from the user. Now, after this much input I create the material, its configuration profile through the ABAP code. For this I know I have to make relevant entries in tables MARA, MAKT, CUCO.. and also check for the existence of the class in the table KLAH.
Now the point where I am stuck is that I am not able to get how to assign the class to the material through the code. I am able to get the internal class id from the table KLAH but I am not able to figure how the internal material number is being generated in the table INOB and i need this number as well as the internal class id number to insert a record in the table KSSK to show proper assignment.
Can anyone please suggest me some solutions?
Thanks....Hi,
I tried using BAPI_OBJCL_CREATE. In order to understand it functioning better I created a material and class (of type 300) through transactions MM01 and cl01 respectively. Then i created a report and called the FM BAPI_OBJCL_CREATE, gave the material name as the material above, table as MARA, class as the one i created above and class type 300. I even analysed the message of the table return (return-message) after executing the report. The messahe said assignment done. But when I checked mnaually in cl20n there was no assignment done to the required material. There was also no entry for the required material in the table INOB which I need.
Can anyoene tell me that where am i going wrong? Please do help. -
How to assign the dynamic value of PV to Sip Header in ICM?
Hi everybody,
I would like to ask your help, please. We are working on Temporary IVR Handoff (ICM+CVP). I need to add/modify a customer Sip header in ICM transfer script. The value for that header is dynamic and stored in the one of ICM Call Peripherial Variables (PV9, for examle).
Is it possible somehow to assign the value of that PV9 to Sip header (Set Variable Call.SipHeader)? I tried to do it but unfortunally without any success. I can assign any static string, but how to assign the value of the PV??? That's the question...
For static string assignment the syntax of the Set Variable Node (Call.SipHeader) looks like that:
"IVR-Handoff~add~It's Cisco"
and it works fine.
For dynamic value (PV9) I tried:
"IVR-Handoff~add~Call.PeripherialVariable9" - it add Call.PeripherialVariable9 as a string, but not it's value;
"IVR-Handoff"~add~Call.PeripherialVariable9 - returns a syntax error;
Call.PeripherialVariable9 - no Sip header is added.
What do you think? Is it doable at all?
Any ideas, answers or examples how to do it would be much appreciated.
Thank you in advance.
Dmitriy.Hi Senthil,
Yes! It works, but with the little difference. The right answer is:
"IVR-Handoff~add~"&Call.PeripherialVariable9
(Call.PeripherialVariable9 is without quotes, otherwise it insert the name of the variable, but not it's value)
The other solution is shown here (thanks to Paul Tindall):
http://developer.cisco.com/web/cvp/forums/-/message_boards/message/15627744?p_p_auth=6psgR8ML
concatenate("IVR-Handoff~add~",Call.PeripherialVariable9)
Thank you so much for the idea! I very appreciate your help and vote you. -
How to assign the downloaded file path in dropdown menu dynamically?
I have one jsp page. In that jsp page one dropdown menu is there. Dropdown menu contains "save" and "saved content". I download the file using "save" option in menu. That downloaded file path is assigned to the below of the "saved content" option. Then i clicked that downloaded file path, that file will be open.
My problem is how to assign the downloaded file path in dropdown menu. plz help me.dittu wrote:
My problem is how to assign the downloaded file path in dropdown menu. plz help me.I don't understand your problem. -
How to set the initial value of of a poplist dynamical
Hi,
I've got a poplist that is populated by a recordgroup. This is done by the following pre-form trigger:
DECLARE
l_query_ok NUMBER;
l_group_id RecordGroup;
l_it_id item;
l_int_value VARCHAR2(2);
BEGIN
l_it_id := Find_item('MERGED_ISSUER.product_code');
l_group_id := FIND_GROUP('RG_PRODUCT_CODE');
l_query_ok := POPULATE_GROUP(l_group_id);
-- Populate list 'Product Code'
CLEAR_LIST (l_it_id);
POPULATE_LIST(l_it_id,l_group_id);
END;
I've tried to set the initial value by adding following lines to the trigger above but I receive the frm-41084 error. This code assigns the first value of the recordgroup to a hidden text item. In the properties of the poplist the value of the hidden text field is set as initial value.
-- Set initial value
l_int_value := Get_Group_Char_Cell('RG_PRODUCT_CODE', 1);
:MERGED_ISSUER.int_value := l_int_value;
Any help?
thxHello Ken,
you can set an initial value for a poplist with the copy command.
You could use a procedure like this:
PROCEDURE P_FILL_LBX
lbx_ITEM_IN VARCHAR2,
grp_DATA_GROUP_IN VARCHAR2,
flg_DEL_NULL BOOLEAN,
str_WERT_IN VARCHAR2
) IS
ERROR_ID NUMBER;
BEGIN
CLEAR_LIST(lbx_ITEM_IN);
ERROR_ID := populate_group(grp_DATA_GROUP_IN);
populate_list(lbx_ITEM_IN,grp_DATA_GROUP_IN);
IF flg_DEL_NULL = TRUE THEN
DELETE_LIST_ELEMENT(lbx_ITEM_IN,GET_LIST_ELEMENT_COUNT(lbx_ITEM_IN));
END IF;
IF str_WERT_IN IS NOT NULL THEN
COPY(str_WERT_IN,''||lbx_ITEM_IN||'');
END IF;
END;Bernd -
How to config the Default Values in IT 2006
Dear Gurus,
My Client requirement is if i create Absence quota they want default quotas values
eg PL= 40
CL=7
SL=5
Then how to config the Default Values in IT 2006
Other wise where i have to assign in Quotas limit
Please advised
Regards
MHPOConfigure ur Absence Quotas with Selection group and assign the value of that selection group in Quomo
and run RPTQTA00
Time Data Personnel Time Management IMG Managing Time Accounts Using Attendance/AbsenceRecording and Administration Define Absence Quota Types. Time Quota Types Quotas
PersonnelIMG Managing Time Time Data Recording and Administration Time Management Calculating Absence Entitlements Accounts Using Attendance/Absence Quotas Permit Quota Generation Without TimeAutomatic Accrual of Absence Quotas Evaluation.
Time Time Evaluation Personnel Time Management IMG Set Personnel Subarea Groupings for Time Recording.Evaluation Settings
PersIMG Time Data Recording and Administration onnel Time Management Calculating AbsenceManaging Time Accounts Using Attendance/Absence Quotas Set Base Entitlements Rules for Generating Absence Quotas Entitlements Base Entitlement for Absence Quota Generation.
Personnel TimeIMG Managing Time Accounts Time Data Recording and Administration Management Rules for Calculating Absence Entitlements Using Attendance/Absence Quotas Determine Validity and Deduction Periods.Generating Absence Quotas
IMG Managing Time Data Recording and Administration Personnel Time Management Calculating Absence EntitlementsTime Accounts Using Attendance/Absence Quotas Define Set Base Entitlements Rules for Generating Absence Quotas Generation Rules for Quota Selection.
Define Public Holiday Work Schedules Personnel Time Management IMG Classes
Personnel Work Schedules Personnel Time Management IMG Group Personnel Subareas for the Work ScheduleSubarea Groupings
IMG Group Personnel Subarea Groupings Work Schedules Personnel Time Management Personnel Subareas for theDaily Work Schedule
Daily Work Schedules Work Schedules Personnel Time Management IMG Define Daily Work Schedules
Work Personnel Time Management IMG Define Period Work Schedules. Period Work Schedules Schedules
IMG Define Day Day Types Work Schedules Personnel Time Management Types.
Day Types Work Schedules Personnel Time Management IMG Define Day Types.
Day Work Schedules Personnel Time Management IMG Define Special Days.Types
Work Personnel Time Management IMG Define Employee Subgroup Work Schedule Rules and Work Schedules Schedules Groupings
Work Work Schedules Personnel Time Management IMG Define Groupings for the Public HolidaySchedule Rules and Work Schedules Calendar.
Work Work Schedules Personnel Time Management IMG Set Work Schedule Rules and WorkSchedule Rules and Work Schedules Schedules.
Work Work Schedules Personnel Time Management IMG Generate Work Schedules ManuallySchedule Rules and Work Schedules
IMG Set Planned Working Time Work Schedules Personnel Time Management Default Value for the Work Schedule.
Personnel Time Management IMG Set Default Value for Time Management Planned Working Time Work Schedules Status.
Time Data Recording and Personnel Time Management IMG Define Personnel Subareas for Substitution Substitutions Administration Types.
Time Data Recording and Personnel Time Management IMG Set Defaults for Substitution Types. Substitutions Administration
IMG Absences Time Data Recording and Administration Personnel Time Management Group Personnel Subareas for Attendances and Absence Catalog Absences.
Time Data Recording and Personnel Time Management IMG Define Absence Types. Absence Catalog Absences Administration
IMG Absences Time Data Recording and Administration Personnel Time Management Define Counting Classes for the Period Work Absence Counting Absence Catalog Schedule.
Time Data Recording and Personnel Time Management IMG Rules for Absence Counting Absence Catalog Absences Administration Group Employee Subgroups for Time Quotas.Absence Counting (New)
IMG Absences Time Data Recording and Administration Personnel Time Management Group Rules for Absence Counting (New) Absence Counting Absence Catalog Personnel Subareas for Time Quotas
Time Personnel Time Management IMG Absence Absence Catalog Absences Data Recording and Administration Define Rules for Rounding Counted Rules for Absence Counting (New) Counting Absences
Time Data Recording and Personnel Time Management IMG Rules for Absence Counting Absence Catalog Absences Administration Define Counting RulesAbsence Counting (New)
Personnel TimeIMG Absence Catalog Absences Time Data Recording and Administration Management Define Counting Rules Rules for Absence Counting (New) Absence Counting Deduction rules for Absence quotas
Time Personnel Time Management IMG Absence Absence Catalog Absences Data Recording and Administration Assign Counting Rules to Absence Types.Counting
Personnel TimeIMG Attendances/Actual Working Time Data Recording and Administration Management Define Attendance Types.Times
Time Personnel Time Management IMG Attendances/Actual Working Times Data Recording and Administration Assign Counting Rules for Attendance counting (New) Attendance counting Rules to Attendance Types.
Time Data Personnel Time Management IMG Managing Time Accounts Using Attendance/AbsenceRecording and Administration Define Absence Quota Types. Time Quota Types Quotas
PersonnelIMG Managing Time Time Data Recording and Administration Time Management Calculating Absence Entitlements Accounts Using Attendance/Absence Quotas Permit Quota Generation Without TimeAutomatic Accrual of Absence Quotas Evaluation.
Time Time Evaluation Personnel Time Management IMG Set Personnel Subarea Groupings for Time Recording.Evaluation Settings
Time Data Recording and Administration Personnel Time Management IMG Managing Calculating AbsenceTime Accounts Using Attendance/Absence Quotas Set Base Entitlements Rules for Generating Absence Quotas Entitlements Base Entitlement for Absence Quota Generation.
Personnel TimeIMG Managing Time Accounts Time Data Recording and Administration Management Rules for Calculating Absence Entitlements Using Attendance/Absence Quotas Determine Validity and Deduction Periods.Generating Absence Quotas
IMG Managing Time Data Recording and Administration Personnel Time Management Calculating Absence EntitlementsTime Accounts Using Attendance/Absence Quotas Define Set Base Entitlements Rules for Generating Absence Quotas Generation Rules for Quota Selection. -
How to get the selected values from a selectmanylistbox?
Hi ADF Experts,
<af:selectManyListbox label="Label 1" id="sml1" partialTriggers="cb2"
value="#{viewScope.TestBean.lovValue}"
autoSubmit="true" valuePassThru="true">
<f:selectItems value="#{viewScope.TestBean.actualList}" id="si1"
binding="#{viewScope.TestBean.selectedItems}"/>
</af:selectManyListbox>
<af:commandButton text="get selected values" id="cb3"
actionListener="#{viewScope.TestBean.getSelectedValues}"
partialSubmit="true"/>
private List<String> lovValue;
private List<SelectItem> actualList;
//getters and setters
public void getSelectedValues(ActionEvent actionEvent) {
// Add event code here...
for (String selectedItem : lovValue) {
System.out.println("Selected item: " +selectedItem.); // this is giving 1 and 3 like this. how to get the checked values as I'm getting only the indexes. In this scenario I am populating the list programmatically.Just I wanted to know how can we get the selected values(not indexes). Please suggest.
Thanks-
AbhijitHi Timo,
As I am sharing the page fragment and the Java class. So its my usecase I have mentioned below
I am sharing the jsff page fragment and java class. So that it wud be of help to others.
jsff page fragment
<?xml version='1.0' encoding='UTF-8'?>
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
xmlns:f="http://java.sun.com/jsf/core">
<af:panelGroupLayout id="pgl1">
<af:commandButton text="Search" id="cb1"
actionListener="#{viewScope.TestBean.searchSupplier}"/>
</af:panelGroupLayout>
<af:popup id="p1" binding="#{viewScope.TestBean.searchSupplierPopup}">
<af:dialog id="d2"
type="none">
<af:table value="#{bindings.Contacts.collectionModel}" var="row"
rows="#{bindings.Contacts.rangeSize}"
emptyText="#{bindings.Contacts.viewable ? 'No data to display.' : 'Access Denied.'}"
fetchSize="#{bindings.Contacts.rangeSize}"
rowBandingInterval="0"
binding="#{viewScope.TestBean.tsupportIssues}"
filterModel="#{bindings.ContactsQuery.queryDescriptor}"
queryListener="#{bindings.ContactsQuery.processQuery}"
filterVisible="true" varStatus="vs"
selectionListener="#{bindings.Contacts.collectionModel.makeCurrent}"
rowSelection="multiple" id="t1">
<af:column sortProperty="name" filterable="true" sortable="true"
headerText="#{bindings.Contacts.hints.name.label}" id="c2">
<af:outputText value="#{row.name}" id="ot1"/>
</af:column>
<af:column sortProperty="email" filterable="true" sortable="true"
headerText="#{bindings.Contacts.hints.email.label}"
id="c1">
<af:outputText value="#{row.email}" id="ot2"/>
</af:column>
</af:table>
<af:commandButton text="OK" id="cb5" partialSubmit="true" actionListener="#{viewScope.TestBean.testMethod}"/>
<af:commandButton text="Cancel" id="cb6"
actionListener="#{viewScope.TestBean.cancelPopupSearch}"/>
</af:dialog>
</af:popup>
<af:selectManyListbox label="Label 1" id="sml1" partialTriggers="cb5"
value="#{viewScope.TestBean.lovValue}"
autoSubmit="true" valuePassThru="true"
binding="#{viewScope.TestBean.prp1}">
<f:selectItems value="#{viewScope.TestBean.actualList}" id="si1"
binding="#{viewScope.TestBean.selectedItems}"/>
</af:selectManyListbox>
<af:commandButton text="get selected values" id="cb3"
actionListener="#{viewScope.TestBean.getSelectedValues}"
partialSubmit="true"/>
<af:commandButton text="remove selected" id="cb4"
partialSubmit="true" actionListener="#{viewScope.TestBean.removeSelectedValues}"/>
</jsp:root>
TestBean.java
package com.demo.view;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import javax.faces.component.UISelectItems;
import javax.faces.event.ActionEvent;
import javax.faces.model.SelectItem;
import oracle.adf.model.BindingContext;
import oracle.adf.model.binding.DCBindingContainer;
import oracle.adf.model.binding.DCIteratorBinding;
import oracle.adf.view.rich.component.rich.RichPopup;
import oracle.adf.view.rich.component.rich.data.RichTable;
import oracle.adf.view.rich.component.rich.input.RichSelectManyListbox;
import oracle.adf.view.rich.context.AdfFacesContext;
import oracle.adf.view.rich.event.DialogEvent;
import oracle.jbo.Key;
import oracle.jbo.Row;
import oracle.jbo.RowSetIterator;
import org.apache.myfaces.trinidad.model.RowKeySet;
public class TestBean {
private RichTable tsupportIssues;
private List<SelectItem> lovValue;
private List<SelectItem> actualList;
private RichSelectManyListbox prp1;
private List valuesChoosed = new ArrayList();
private UISelectItems selectedItems;
private RichPopup searchSupplierPopup;
public TestBean() {
super();
public void setTsupportIssues(RichTable tsupportIssues) {
this.tsupportIssues = tsupportIssues;
public RichTable getTsupportIssues() {
return tsupportIssues;
public void testMethod(ActionEvent actionEvent) {
// Add event code here...
// For learning purposes - show Select Many Button clicked
System.out.println("Select Many Button has been Clicked");
// // RowKeySet Object can hold the selected rows from a user as follows
RowKeySet rksSelectedRows = this.getTsupportIssues().getSelectedRowKeys();
// Iterator object provides the ability to use hasNext(), next() and remove() against the selected rows
Iterator itrSelectedRows = rksSelectedRows.iterator();
// Get the data control that is bound to the table - e.g.
// OpenSupportItemsIterator
DCBindingContainer bindings = (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry();
DCIteratorBinding dcIteratorBindings = bindings.findIteratorBinding("findAllContactsIterator");
// Information from binding that is specific to the rows
RowSetIterator rsiSelectedRows = dcIteratorBindings.getRowSetIterator();
// Loop through selected rows
int i=1;
while (itrSelectedRows.hasNext()) {
// Get key for selected row
Key key = (Key)((List)itrSelectedRows.next()).get(0);
// Use the key to get the data from the above binding that is related to the row
Row myRow = rsiSelectedRows.getRow(key);
// Display attribute of row in console output - would generally be bound to a UI component like a Label and or used to call another proces
System.out.println(myRow.getAttribute("name"));
valuesChoosed.add(myRow.getAttribute("name"));
// actualList = new ArrayList<SelectItem>();
// String j = Integer.toString(i);
// actualList.add(new SelectItem(j, (String)myRow.getAttribute("name")));
// i++;
searchSupplierPopup.hide();
AdfFacesContext.getCurrentInstance().addPartialTarget(prp1);
public void setLovValue(List<SelectItem> lovValue) {
this.lovValue = lovValue;
public List<SelectItem> getLovValue() {
return lovValue;
public void setActualList(List<SelectItem> actualList) {
this.actualList = actualList;
public List<SelectItem> getActualList() {
actualList = new ArrayList<SelectItem>();
if(valuesChoosed.size()!=0){
for(int i=0;i<valuesChoosed.size();i++){
actualList.add(new SelectItem(valuesChoosed.get(i), (String)valuesChoosed.get(i)));
else{
actualList.add(new SelectItem("1","Select One"));
return actualList;
public void setPrp1(RichSelectManyListbox prp1) {
this.prp1 = prp1;
public RichSelectManyListbox getPrp1() {
return prp1;
public void setValuesChoosed(List valuesChoosed) {
this.valuesChoosed = valuesChoosed;
public List getValuesChoosed() {
return valuesChoosed;
public void getValues(ActionEvent actionEvent) {
// Add event code here...
for(int i=0;i<valuesChoosed.size();i++){
System.out.println(valuesChoosed.get(i));
public void getSelectedValues(ActionEvent actionEvent) {
// Add event code here...
for(int i=0;i<this.getLovValue().size();i++){
System.out.println("Selected Value:"+this.getLovValue().get(i));
public void removeSelectedValues(ActionEvent actionEvent) {
// Add event code here...
public void setSelectedItems(UISelectItems selectedItems) {
this.selectedItems = selectedItems;
public UISelectItems getSelectedItems() {
return selectedItems;
public void setSearchSupplierPopup(RichPopup searchSupplierPopup) {
this.searchSupplierPopup = searchSupplierPopup;
public RichPopup getSearchSupplierPopup() {
return searchSupplierPopup;
public void cancelPopupSearch(ActionEvent actionEvent) {
// Add event code here...
searchSupplierPopup.hide();
public void searchSupplier(ActionEvent actionEvent) {
// Add event code here...
RichPopup.PopupHints hints = new RichPopup.PopupHints();
searchSupplierPopup.show(hints);
package com.demo.view;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import javax.faces.component.UISelectItems;
import javax.faces.event.ActionEvent;
import javax.faces.model.SelectItem;
import oracle.adf.model.BindingContext;
import oracle.adf.model.binding.DCBindingContainer;
import oracle.adf.model.binding.DCIteratorBinding;
import oracle.adf.view.rich.component.rich.RichPopup;
import oracle.adf.view.rich.component.rich.data.RichTable;
import oracle.adf.view.rich.component.rich.input.RichSelectManyListbox;
import oracle.adf.view.rich.context.AdfFacesContext;
import oracle.adf.view.rich.event.DialogEvent;
import oracle.jbo.Key;
import oracle.jbo.Row;
import oracle.jbo.RowSetIterator;
import org.apache.myfaces.trinidad.model.RowKeySet;
public class TestBean {
private RichTable tsupportIssues;
private List<SelectItem> lovValue;
private List<SelectItem> actualList;
private RichSelectManyListbox prp1;
private List valuesChoosed = new ArrayList();
private UISelectItems selectedItems;
private RichPopup searchSupplierPopup;
public TestBean() {
super();
public void setTsupportIssues(RichTable tsupportIssues) {
this.tsupportIssues = tsupportIssues;
public RichTable getTsupportIssues() {
return tsupportIssues;
public void testMethod(ActionEvent actionEvent) {
// Add event code here...
// For learning purposes - show Select Many Button clicked
System.out.println("Select Many Button has been Clicked");
// // RowKeySet Object can hold the selected rows from a user as follows
RowKeySet rksSelectedRows = this.getTsupportIssues().getSelectedRowKeys();
// Iterator object provides the ability to use hasNext(), next() and remove() against the selected rows
Iterator itrSelectedRows = rksSelectedRows.iterator();
// Get the data control that is bound to the table - e.g.
// OpenSupportItemsIterator
DCBindingContainer bindings = (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry();
DCIteratorBinding dcIteratorBindings = bindings.findIteratorBinding("findAllContactsIterator");
// Information from binding that is specific to the rows
RowSetIterator rsiSelectedRows = dcIteratorBindings.getRowSetIterator();
// Loop through selected rows
int i=1;
while (itrSelectedRows.hasNext()) {
// Get key for selected row
Key key = (Key)((List)itrSelectedRows.next()).get(0);
// Use the key to get the data from the above binding that is related to the row
Row myRow = rsiSelectedRows.getRow(key);
// Display attribute of row in console output - would generally be bound to a UI component like a Label and or used to call another proces
System.out.println(myRow.getAttribute("name"));
valuesChoosed.add(myRow.getAttribute("name"));
// actualList = new ArrayList<SelectItem>();
// String j = Integer.toString(i);
// actualList.add(new SelectItem(j, (String)myRow.getAttribute("name")));
// i++;
searchSupplierPopup.hide();
AdfFacesContext.getCurrentInstance().addPartialTarget(prp1);
public void setLovValue(List<SelectItem> lovValue) {
this.lovValue = lovValue;
public List<SelectItem> getLovValue() {
return lovValue;
public void setActualList(List<SelectItem> actualList) {
this.actualList = actualList;
public List<SelectItem> getActualList() {
actualList = new ArrayList<SelectItem>();
if(valuesChoosed.size()!=0){
for(int i=0;i<valuesChoosed.size();i++){
actualList.add(new SelectItem(valuesChoosed.get(i), (String)valuesChoosed.get(i)));
else{
actualList.add(new SelectItem("1","Select One"));
return actualList;
public void setPrp1(RichSelectManyListbox prp1) {
this.prp1 = prp1;
public RichSelectManyListbox getPrp1() {
return prp1;
public void setValuesChoosed(List valuesChoosed) {
this.valuesChoosed = valuesChoosed;
public List getValuesChoosed() {
return valuesChoosed;
public void getValues(ActionEvent actionEvent) {
// Add event code here...
for(int i=0;i<valuesChoosed.size();i++){
System.out.println(valuesChoosed.get(i));
public void getSelectedValues(ActionEvent actionEvent) {
// Add event code here...
for(int i=0;i<this.getLovValue().size();i++){
System.out.println("Selected Value:"+this.getLovValue().get(i));
public void removeSelectedValues(ActionEvent actionEvent) {
// Add event code here...
for(int i=0;i<this.getLovValue().size();i++){
System.out.println("Selected Value:"+this.getLovValue().get(i));
System.out.println(this.getLovValue().remove(i));
AdfFacesContext.getCurrentInstance().addPartialTarget(prp1);
public void setSelectedItems(UISelectItems selectedItems) {
this.selectedItems = selectedItems;
public UISelectItems getSelectedItems() {
return selectedItems;
public void setSearchSupplierPopup(RichPopup searchSupplierPopup) {
this.searchSupplierPopup = searchSupplierPopup;
public RichPopup getSearchSupplierPopup() {
return searchSupplierPopup;
public void cancelPopupSearch(ActionEvent actionEvent) {
// Add event code here...
searchSupplierPopup.hide();
public void searchSupplier(ActionEvent actionEvent) {
// Add event code here...
RichPopup.PopupHints hints = new RichPopup.PopupHints();
searchSupplierPopup.show(hints);
Thanks,
A. Abhijit -
SRM 4.0- How to set the default values for product type (01) only for SC
The radio button Service should not be visible.
Also for search help (e.g. search for internal products) where a search should only be possible for product type 01 (goods). The system should not display the product type and internally always search for goods only.
How to set the default values for product type (01) only for SC
We needs to use Search help BBPH_PRODUCT which having parameter PRODUCT_TYPE
Here we can set defalut value 01 but it is not correct one since same search help is using several places.
We need to limit the search help results only for SC.
Kindly help out me ASAP.The easiest way to set defautl values is to edit the batch class.
Goto the characteiristic and go to update values.
In here you probably have something like 0 - 100 as a spec range.
On the next line enter the default value within this range. At the end of the line, click in the box in the column labelled "D". This indicates the defautl value for the characteristic.
If you need to you can do this in the material classification view as well.
Just to be clear, these values will only show up in the batch record. You can not have defautl values in resutls recording screens.
FF
Maybe you are looking for
-
Late 2012 Mac Mini - Random spinning beachball then crash.
Hi, I have a late 2012 Mac Mini bought last summer. Since the early days I would randomly get the spinning beach ball and there was no bringing it back. A re-boot would be required. I upgraded to Yosemite and the issue still occurs. I could literally
-
Setting a default color for messages in Mail
I figured out how to change the default font & font size in messages in the Mail application, and how to change the color in my signature, however I cannot figure out how to set the default color for new messages?
-
Trying to install my cs2 disk my serial number is not reconized
trying to install cs2 on new laptop, old hard drive in desktop with origanial install on it crashed can't think why this is not working
-
I went to REGEDIT and installed the DWORD key as suggested by ADOBE to fix problem created by security update & it did NOT work!! Attempting to save then open the files gives same error msg. I sent multiple emails from a book scanner at the library
-
My phone was recently exchanged under warranty for a number of faults.. one of which was that on occasions, I cannot hear the caller, but they can hear me. Hang up the call. the caller calls back and everything is OK. So today, my exchanged phone did