DROP DOWN BASED ON FILTERS
TABLE IS HAVING FOLLOWING DATA
USER MATNO MATERIAL TYPE FLD4 FLD5
TOM M001 A
TOM M002 B
TOM M005 C
TOM M007 D
ROBERT M001 A
ROBERT M006 B
ROBERT M067 C
ROBERT M012 D
RAM M009 F
RAM M076 G
RAM M097 Y
RAM M072 H
ON THIS TABLE I AM CREATING WEB REPORT
WEB REPORT IS HAVING THREE DROP DOWNS
MY REQUIREMENT IS
WHEN I EXECUTE THE REPORT
BY GIVING USER NAME AS 'RAM'
I SHOULD GET ONLY M009,M076,M097,M072 IN THE MATERIAL DROP DOWN
WHAT R THE SETTING I SHOULD MAKE ?
PLEASE SUGGEST ME
I WILL ASSSIGN POINTS
Hi Vishal,
check this links,
http://help.sap.com/saphelp_nw04/helpdata/en/37/56f438114ee836e10000000a114084/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/80/1a68a7e07211d2acb80000e829fbfe/frameset.htm
Hope this helps,
Sudhakar.
Similar Messages
-
Want to hide the drop down based on text field value
Hi,
I want to hide some of the values in drop down based on one text field value.
I have the field called name which has the value A, B, C, D and also one drop down list which has the values 1,2,3,4,5,6. I want to hide the some of the values in drop down based on A or B or C. Let say, If it is A, drop down value should be 1,3,5. If it is B, Drop down value should be 1,2,3,4. Like this for every record.
Can you please help me out.
Thanks
RamHi Robert,
I am trying it in two different way. Please suggest which is the right one and feasible.
1) I have the drop down list which has all the status. I am trying to hide the drop down values based on one text field value for all records.
2) I have collected all the drop down values into table in webdynpro method. Rightnow I have two tables.
one has line items details and another one have drop down values. both tables having common fields.
I have to show second table values for that particular key, move all of them to drop down.
Which is the best and feasible option.
Thanks
Ram -
How to get value in Second Drop Down based on selection made in first dropd
Hi All,
I have a table with first two columns as dropdown.
The values in first drop down are fixed. However the value in second dropdown should be populated based on selection made in first .
e.g
First Column had different departments say IT, SALES, HR.
Based on department selected I have to populate employee of that department.
For first dropdown I have taken Drop down by index.
What should I select for second drop down and achieve desired functionality? Please guide.
Regards,
MadhvikaHi
Use drop down by key for fixed values IT, SALES, HR. create on_select action for that drop down.
in on_select method code like this..
DATA lo_nd_segment1 TYPE REF TO if_wd_context_node.
DATA lo_el_segment1 TYPE REF TO if_wd_context_element.
DATA ls_segment1 TYPE wd_this->Element_segment1.
data lt_segment1 type wd_this->elements_segment1.
DATA lv_segment TYPE wd_this->Element_segment1-segment.
data lr_column type ref to cl_wd_table_column.
navigate from <CONTEXT> to <SEGMENT1> via lead selection
lo_nd_segment1 = wd_context->get_child_node( name = wd_this->wdctx_segment1 ).
get element via lead selection
lo_el_segment1 = lo_nd_segment1->get_element( ).
lo_el_segment1 = WDEVENT->GET_CONTEXT_ELEMENT( 'CONTEXT_ELEMENT' ).
get all declared attributes
lo_el_segment1->get_static_attributes(
IMPORTING
static_attributes = ls_segment1 ).
now ls_segment1 contains your first drop down selection value.
DATA : lv_dropdown type string .
lv_dropdown = ls_segment1-segment.
if lv_dropdown = 'IT'.
// here fill your second drop down based on IT value.
endif.
Hope it solves.
Cheers,
Kris. -
How to populate Second drop down based on the first drop down value
Hi Experts,
i have a HTML BSP page. with 2 drop down with SELECT and OPTION tags. i need to populate the second drop down based on the first drop down value.
i tried HTMLB script they work good as stand alone when i try to embed the HTMLB with HTML it does not work.
Please can you give me a solution only with ABAP script and HTML.
please clearly let me know on what event i should implement it. sample code is really appreciated .
With regards,
ChellaYou can have event handler for first drop down . Then populate the data for 2nd field when the event triggers on first field.
-
Cond display of drop down based on value selected in another drop down form
Hi,
I have a requirement in my app in which I need to be able to conditionally display the values in the drop down down list based on the values selected in another drop down list...
Currently I have 2 drop downs.
First drop down is a list of Jacks from 2000 to 4999...
Second Drop down consists Chassis ranging from 1 to 900..
So when a user selects any jack between 2000 - 2999, in the second drop down only Chassis ranging from 1 to 300 should appear.
when anything between 3000 - 3999 is selected, Chassis ranging from 301 to 600 should appear..
and for jacks between 4000 - 4999, Chassis ranging from 601 to 900 should appear in the second drop down.
Can someone please provide me pointers on how to do this..
Thanks,
NehalHi Larry,
Thanks for your response..
Here are the queries for my select lists.
P62_JACK
select list query for Jacks:
select JACK_NUM display_value, JACK_NUM return_value
from CTS_LIST_OF_JACKS
order by 1
P62_CHASSIS_BLADE_PORT
select NETWORKPORT display_value, NETWORKPORT return_value
from CTS_LIST_OF_NETWORKPORTS
order by NETWORKPORT_ID
jacks range from 2000 to 4000
chassis_blade_port ranges from 100 to 900...
Can you please let me know how to do it..
Thanks,
Nehal -
Update Drop Down based on selection in Option group
Good afternoon all-
I've got an option box ('PanelStatus') with two options: "Panel" (value of 1) and "Non-Panel" (value of 2).
On the form where this is located, I have a drop down box filled with names. These people on this table are either Panel or Non-Panel. So, my idea is that the drop down with names will be refreshed when the radio buttons in PanelStatus are clicked.
I've got a query that will return the right results, based on what's selected in the Option Group. However, when I set the Option Group after update event to refresh the dropdown box, Access is telling me "Object doesn't support this property
or method".
Any ideas/help are welcome!
EDIT: I'm thinking it may be because the drop down is unbound...? Does that explain why this is not working? If so, any ideas how to do this with the drop down remaining unbound?The After Update event of an option group works whether the option group is bound or unbound.
You should use the Requery method of the combo box.
Regards, Hans Vogelaar (http://www.eileenslounge.com) -
Need cascading drop downs based on non hierarchial attributes
Post Author: Out of the box thinking
CA Forum: WebIntelligence Reporting
Using BO XI Web Intelligence. I am trying to create multiple dropdowns to dictate the data input for a report. The drop downs should include attribute values for products. (EG: Color, Size, Flavor, Brand etc) these attributes do not follow a structured hierarchy and does not have a parent to child relationship. I am trying to dictate the values that should be shown in all dropdowns based on the value selected in any drop down. For example, if the user selects "Red" from the "color" drop down, Brand dropdown content should only include those brands that have "Red" products. Similarly, "Flavor" dropdown should only show the flavors that has "Red" products. These dropdowns should not be in the report body. They should be in the left hand user control menu.
Is this something already available? If not, any work arounds?
I appreciate any inputs.Hi,
First of all: if I understand you correctly, you do want your checkbox value to be available within the view object. If so, you need to make it a transient attribute of your VO and your checkbox must be databound to that attribute (you were talking about a non-databound item). Whether the item relates to anything in the database is irrelevant from a JHeadstart point of view.
Your second question is actually an ADF related question, it has nothing to do with JHeadstart. In general I would say that you either update View Object attributes immediately when the flag is changed, or you do it in the Entity itself at Commit-time. What you are suggesting seems like an area for architectural improvement.
Regards
Evert-Jan de Bruin
JHeadstart Team -
Oracle ADF Populate Drop Down based on Parameter
Hi All,
I have been struggling with a scenario where we want the values in a drop down to be limited based on something specifc....so for instance the users department ID. If that value exists in the view object that is displaying the data and where I will have my LOV it works fine to restrict the LOV based on the user's department id.
However, if that value isn't in that view object we are using to display the form values along with the LOV then I can get the value listing to be restricted. I have tried execute with params and a few other things (This works to restrict data on the page, but not the LOV).
Any tips on how I can restrict an LOV based on a value that is not in the current VO would be great.
Thanks,
SFrank,
I Found your previous example and it worked like a charm thanks.
Put this in the view accessor like you said and it did what I wanted: adf.source.applicationModule.findViewObject('departmentsInLocation').currentRow.DepartmentId
--S -
Changing value in drop-down based on selected value in another drop-down
Hi,
I have two drop-downs - changing value in Combo1, should cause the form to be submitted and values to be populated in Combo 2.
Approaches i tried - 1) I am using an ActionListener. I am having a valueChange method which accepts an action event. However this appraoch is not working for me. 2) I was wondering if I could use Javacsript to catch the OnChange event , the javascript function would call an appropirate method in my ActionListener. I know in Struts its straightforward, but how do i achive the same here in JSF.
Any tips would be helpful.
Thanks
PS: I already came across some threads in the forum, but could not get an answer. Also, I have a retsriction in terms of using Action LIsteners itself.Try using ValueChangeListener instead of ActionListener.
Here's a working example of a ValueChangeListener. You can customize it and use it for your application.
The JSP will look like this:
<h:selectOneMenu value="#{globalsBean.selectedFirst}"
valueChangeListener="#{globalsBean.changeList}" onchange="submit()">
<f:selectItems value="#{globalsBean.first}" />
</h:selectOneMenu>
<h:selectOneMenu value="#{globalsBean.selectedSecond}">
<f:selectItems value="#{globalsBean.second}" />
</h:selectOneMenu>The globalsBean will look like this:
public class GlobalsBean extends Bean {
ArrayList first;
ArrayList second;
String selectedFirst;
String selectedSecond;
public GlobalsBean() {
first = new ArrayList();
second = new ArrayList();
first.add(new SelectItem("1", "1"));
first.add(new SelectItem("2", "2"));
selectedFirst = "1";
selectedSecond = "";
second.add(new SelectItem("White", "White Cows"));
second.add(new SelectItem("Brown", "Brown Cows"));
second.add(new SelectItem("Green", "Green Cows?!?"));
public ArrayList getFirst() {
return first;
public ArrayList getSecond() {
return second;
public String getSelectedFirst() {
return selectedFirst;
public void setSelectedFirst(String selected) {
selectedFirst = selected;
public String getSelectedSecond() {
return selectedSecond;
public void setSelectedSecond(String selected) {
selectedSecond = selected;
public void changeList(ValueChangeEvent event) throws AbortProcessingException{
second = new ArrayList();
String newValue = (String)event.getNewValue();
setSelectedFirst(newValue);
if (newValue.equals("1")) {
second.add(new SelectItem("White", "White Cows"));
second.add(new SelectItem("Brown", "Brown Cows"));
second.add(new SelectItem("Green", "Green Cows?!?"));
} else if (newValue.equals("2")) {
second.add(new SelectItem("White/Black", "White Cows with Black spots"));
second.add(new SelectItem("Black", "Black Cows"));
setSelectedSecond("");
}Let me know how it works out for you.
CowKing -
How to select drop down based on country selected in one field
Dear Experts,
I am facing a problem,
I have a table in webdynpro, where there are two columns namely Country and its Subtype.
here both the fields are drop down by key type.
when i am selecting Country field from drop down. I am getting its subtype correctly populated in other column.
But when i am selecting the country in next row, It is removing the subtype text of 1st row and giving its code.
Also Now In Column Subtype, It is Showing the dropdown related to the current selected country.
Kindly help.
Regards
SushilHi Sushil,
I guess the value for subtype is depending on the country value, which is fetch from the static value( Usually lead selected value). To avoid this we can either set the current row as lead selected row before populating subtype value or with the following code which will give the element value for the row which is selected rather than the lead selected row and then pass the value for fetching country type.
data: lr_element type ref to if_wd_context_element.
lr_element = wdevent->get_context_element( 'CONTEXT_ELEMENT' ). " Wdevent is the paramter in the "event handler
Regards,
Harsha -
Filter query based on a value from a drop down menu
I am using ADFBC/JDev 10.1.3/ADF-faces (JSPX)
I would like to display a table of data based on a view object and have a drop down menu of values that the user can select from which would filter the table of data. The filter would be applied to a field in the VO. For example, have a JSPX page that shows all employees and have a drop down menu that filters the employees by a specific department with an option to show all departments too in the drop down. I'm not sure if Steve Muench's example #76 (http://radio.weblogs.com/0118231/stories/2004/09/23/notYetDocumentedAdfSampleApplications.html) would serve as a basis for this requirement or not.
Can anybody give me high level guidance on how to do this? Both declaratively and programmatically would be great.
Thanks,
QuocI can't get the JSPX page to display the correct data. It's displaying the entire VO and when you try to select Yes or No or All from the drop down menu, it just changes the Active Flag column in the table to whatever you select for the first row only and still displays the rest of the rows in the VO.
Here's my JSPX code:
<?xml version='1.0' encoding='windows-1252'?>
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:af="http://xmlns.oracle.com/adf/faces"
xmlns:afh="http://xmlns.oracle.com/adf/faces/html"
xmlns:cust="http://xmlns.oracle.com/adf/faces/customizable">
<jsp:output omit-xml-declaration="true" doctype-root-element="HTML"
doctype-system="http://www.w3.org/TR/html4/loose.dtd"
doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN"/>
<jsp:directive.page contentType="text/html;charset=windows-1252"/>
<f:view>
<afh:html>
<afh:head title="showEmployees">
<meta http-equiv="Content-Type"
content="text/html; charset=windows-1252"/>
</afh:head>
<afh:body>
<af:messages/>
<h:form>
<af:panelForm>
<af:selectOneChoice value="#{bindings['bind_active_flag1'].inputValue}"
label="#{bindings['bind_active_flag1'].label}">
<f:selectItems value="#{bindings['bind_active_flag1'].items}"/>
</af:selectOneChoice>
<af:commandButton actionListener="#{bindings.ExecuteWithParams.execute}"
text="ExecuteWithParams"
disabled="#{!bindings.ExecuteWithParams.enabled}"/>
</af:panelForm>
<af:table value="#{bindings.EmployeesView.collectionModel}" var="row"
rows="#{bindings.EmployeesView.rangeSize}"
first="#{bindings.EmployeesView.rangeStart}"
emptyText="#{bindings.EmployeesView.viewable ? 'No rows yet.' : 'Access Denied.'}">
<af:column sortProperty="EmployeeId" sortable="true"
headerText="#{bindings.EmployeesView.labels.EmployeeId}">
<af:outputText value="#{row.EmployeeId}">
<f:convertNumber groupingUsed="false"
pattern="#{bindings.EmployeesView.formats.EmployeeId}"/>
</af:outputText>
</af:column>
<af:column sortProperty="FirstName" sortable="true"
headerText="#{bindings.EmployeesView.labels.FirstName}">
<af:outputText value="#{row.FirstName}"/>
</af:column>
<af:column sortProperty="LastName" sortable="true"
headerText="#{bindings.EmployeesView.labels.LastName}">
<af:outputText value="#{row.LastName}"/>
</af:column>
<af:column sortProperty="ActiveFlag" sortable="true"
headerText="#{bindings.EmployeesView.labels.ActiveFlag}">
<af:outputText value="#{row.ActiveFlag}"/>
</af:column>
</af:table>
</h:form>
</afh:body>
</afh:html>
</f:view>
</jsp:root>Here's the bindings page:
<?xml version="1.0" encoding="UTF-8" ?>
<pageDefinition xmlns="http://xmlns.oracle.com/adfm/uimodel"
version="10.1.3.41.57" id="showEmployeesPageDef"
Package="view.pageDefs"
MsgBundleClass="view.pageDefs.showEmployeesPageDefMsgBundle">
<parameters/>
<executables>
<iterator id="EmployeesViewIterator" RangeSize="10" Binds="EmployeesView"
DataControl="AppModuleDataControl"/>
<variableIterator id="variables">
<variableUsage DataControl="AppModuleDataControl"
Binds="EmployeesView.variablesMap.bind_active_flag"
Name="EmployeesView_bind_active_flag" IsQueriable="false"/>
</variableIterator>
<iterator id="DropDownIterator" RangeSize="-1" Binds="DropDown"
DataControl="AppModuleDataControl"/>
</executables>
<bindings>
<table id="EmployeesView" IterBinding="EmployeesViewIterator">
<AttrNames>
<Item Value="EmployeeId"/>
<Item Value="FirstName"/>
<Item Value="LastName"/>
<Item Value="Email"/>
<Item Value="PhoneNumber"/>
<Item Value="HireDate"/>
<Item Value="JobId"/>
<Item Value="Salary"/>
<Item Value="CommissionPct"/>
<Item Value="ManagerId"/>
<Item Value="DepartmentId"/>
<Item Value="ActiveFlag"/>
</AttrNames>
</table>
<action id="ExecuteWithParams" IterBinding="EmployeesViewIterator"
InstanceName="AppModuleDataControl.EmployeesView"
DataControl="AppModuleDataControl" RequiresUpdateModel="true"
Action="95">
<NamedData NDName="bind_active_flag" NDType="java.lang.String"
NDValue="${bindings.EmployeesView_bind_active_flag}"/>
</action>
<attributeValues id="bind_active_flag" IterBinding="variables">
<AttrNames>
<Item Value="EmployeesView_bind_active_flag"/>
</AttrNames>
</attributeValues>
<list id="bind_active_flag1" IterBinding="EmployeesViewIterator" StaticList="false"
ListOperMode="0" ListIter="DropDownIterator" NullValueFlag="1"
NullValueId="bind_active_flag1_null">
<AttrNames>
<Item Value="ActiveFlag"/>
</AttrNames>
<ListAttrNames>
<Item Value="Value"/>
</ListAttrNames>
<ListDisplayAttrNames>
<Item Value="Description"/>
</ListDisplayAttrNames>
</list>
</bindings>
</pageDefinition>Any ideas? -
Dynamic filter in Design studio using drop-down when data source is Universe
Hi community,
Is there anyway to create Cascading filter in Design studio when data source is Universe using drop-down component (Dimension filters cannot be used in my requirement).
My requirement is,
I have 2 drop-downs:
drop-down 1 : shows the regions in a country.
drop-down 2 : should display states based the region selected in the first drop-down (drop-down 1). Also drop-down 2 should pass selected state as input to the data-source
Thanks in advance
Vivek VJHi Vivek,
Please check out this post: How to Create Multiple Dropdown boxes (Cascading Filters) when using Universe in the backend.
Regards,
Mustafa. -
How to get different values in drop down in table rows
Hi
I have an application, which has a drop down in the table. Each row is to have different values in its drop down based on the "characteristic" parameter. For eg. first row has characteristic as color, and the corresponding drop down will contain the color names. Second row has charateristic as weight, and the drop down will carry corresponding weight values.
I am getting the data from the backend as a flat table i.e. charaterisitc - value pair.
I think i will have to use the Drop Down by Index control, but i dont know how exactly to go about it.
Can any one please help in this regard.
Thanks & regards,
AnupreetHi Maksim
I am sorry, but i am not able to get you.
This is the piece of code that i wrote for populating the drop down:
IPrivateMaintainDocAttribView.IDropElement dropEle = null;
for(int i = 0;i<size;i++)
dropEle = wdContext.nodeDrop().createDropElement();
dropEle.setDropval(wdContext.nodeCtxNode_DocAttribs().getCtxNode_DocAttribsElementAt(i).getCmpCtx_Value());
wdContext.nodeDrop().addElement(dropEle);
Here, Dropis the sub node to which i am putting the data and thisis linked to the table.
CtxNode_DocAttribs is the model node from where i am picking the data and setting in the subnode.
Thanks & regards,
Anupreet -
Hello all,
There are two drop-down boxes. In first drop-down, there are 10 values and in 2nd drop-down, there are 4 values.
When I select one value from first drop-down, based on the selection, in 2nd drop-down, only 3 values should be visible out of 4.
Please let me know whether is it possible in JSP and how should we achive this.
Thanks.It has nothing at all to do with JSPs, JSPs are way too low level for you to want it to solve your requirements. If you want the view to change after it is rendered, you'll have to use client-side logic (javascript) to make it happen in some way or another.
This is why people use modern day web frameworks, they tend to have common solutions to common requirements such as this. But when you choose to use no framework at all, you'll have to roll the solution yourself. Possibly a JQuery component can help you do it a little faster. -
Dynamic change of drop down values
hi gurus,
I got a peculiar senario.
i have three fields on modlue pool screen which are having drop downs.
based on the selected value in the first drop down second drop down values has to display.
suppose.
first drop down displays the bellow values.
technical documents.
type test.
if techincal documents is selected then display the bellow values.
test1
test2
test3
if type test is selected then display the bellow values.
test4
test5
i got the above logic.
one problem is what ever the value i am selecting is reflecting at the end of drop down .
second problem is bellow one.
now suppose that 'type test' is selected in first drop down and 'test5' is selcted in the second drop down.
if suppose again first dorp down selection is changed to 'technical documents' in the second drop down i am getting the bellow values.
test1
test2
test3
test5
already existing value on the screen is reflecting at the end.
but i have to get
test1
test2
test3 only
hope i am clear .
kindly sugest the solution.
thanks in advance ,
padmaja.Assuming your problem is related to custom/z development, i guess abaper might be able to help. In the program clear the internal tables before displaying the values.
rgds
Maybe you are looking for
-
Hi Experts, I'm working on the Xcelcius reportng by using combo box and column chart. Now i want to filter the blank values and to display only the graph where the values are there in the spread sheet. For ex: i've the data for day 1, day 2 ....day20
-
How to modify industry sector of material master data
dear all: i have already created a material master data using a wrong industry sector through tcode MM01. and i have created BOM&ROUTTING for this material. now ,i want to modify the industry sector of this material. what should i do for this case
-
Hi All, We have Enterprise Protal 640 sp11 and we had installed ESS BPESS46C504 on top of it long time back. Now, when I go to any activity in ESS, it usually shows the SAP Easy Access Menu of our backend SAP system and in some places i.e. Leave Requ
-
Field AWKEY in BKPF not working due to case sensitive
Hi, I have reference key as cpv8852MLTD2013, but when i enter this in AWKEY field in BKPF it gets converted to upper case as "CPV8852MLTD2013". Due to this it is not working, and data is not executing.. Please help.. Durga
-
Flash 10 Not Able to Download Due to getPlus + (R) System Error
I cannot download this player to Windows XP. I keep getting Operating Sytem Error 16244.203.296-42072312.80040154.FFFFFFFF80040154. I have tried uninstall, changing authority on IE, turned off security. Anyone got any ideas? Thanks!