External XML data files to add values to drop down lists
I would like to have external XML data files to add values to drop down lists in my form.. But when i create a data connection it is working properly only in the Preview in Livecycle Designer.. but not in the PDF form(Adobe Reader). Moreover im not sure whether it will work in the form manager..!plzz help me!
Raghava Kumar V.S.S.
Hi,
For the case of raghavakumar, Is it really that I need to have LiveCycle Reader Extensions? Is there any other way that could do the same?
Thank you
Similar Messages
-
How to add values to drop down list in adobe forms
how to add values to drop down list in adobe forms
Hi,
If you are using WD Java following are steps of filling values in DD Box:
1 Create a simple type in the Dictionary.
2 Create an attribute "CountryNew" in the Context of type created by you.
3 Write following code in the init method of the form:
IWDAttributeInfo countryinfo =
wdContext.nodeEmployee().getNodeInfo().getAttribute("CountryNew");
ISimpleTypeModifiable Country = countryinfo.getModifiableSimpleType();
IModifiableSimpleValueSet countryValueSet =
Country.getSVServices().getModifiableSimpleValueSet();
countryValueSet.put("IN", "INDIA");
countryValueSet.put("US "USA");
4 Add a Enumrated DD box in the form and bind it to the attribute "CountryNew"
Hope this helps
Amit -
Webdynpro " How to add values in Drop down list By Key"
Hi experts ,
i want to create a drop down list by key, i don't know how to assign values to it ( i.e. add list entries ) . Please help me on this ..
With regards ,
James..
Valuable answers will be rewarded ....Hi,
To fix values to the drop down key at runtime in the webdynpro application you can use the following code:
DATA:
lr_node_flightinfo TYPE REF TO if_wd_context_node,
lr_nodeinfo_flightinfo TYPE REF TO if_wd_context_node_info,
l_scarr type scarr,
lt_value_set TYPE TABLE OF wdr_context_attr_value,
lw_value_set like line of lt_value_set.
get nodeinfo of node flightinfo
lr_node_flightinfo = wd_context->get_child_node( name = 'FLIGHTINFO' ).
lr_nodeinfo_flightinfo = lr_node_flightinfo->get_node_info( ).
get value set (VALUE = CARRID , TEXT = CARRNAME)
select carrid carrname from scarr into table lt_value_set.
clear lw_value_set.
lw_value_set-value = 'AI'.
lw_value_set-text = 'Air India'.
append lw_value_set to lt_value_set.
sort the value set by the describing TEXT
SORT lt_value_set BY text.
set value to context attribute
lr_nodeinfo_flightinfo->set_attribute_value_set(
name = 'CARRID' value_set = lt_value_set ).
Here CARRID is a drop down by key field on the screen.
in The context it is an attribute in the node FLIGHTINFO.
Please give Reward Points if this piece of code helps
Regards,
Manish -
Populating values to drop down list in Adobe Forms
Hi,
We have added a drop down list in our adobe form. Our requirement is Payment Terms should be displayed in this drop down list. We tried by adding values to drop down list in object palette window by using '+' sign. But now we want to display values dynamically from table T052U. We need to bring two fields ZTERM and TEXT1. We don't want to use database connection, just from a table as an importing parameter it should be appended to this list.
Atpresent, we don't want to use webdynpro or java for getting values.
Please provide suitable answers.hi,
cretae simple type in data dictionary i don't have any idea to create simple type in adobe forms.
For creating Simple Type------in Dictionary->Local Dictionary->Data Type->Simple Type(here right click u get create simple type).and after that choose Enumaration Here u can add values
and create a node WITH one attribute and this attribute is off Type of that simple type u created in local dictionary and bind that node with interactive form data source property ,now in interactive form drag and drop that attribte from your dataView Run your application these values will populate in your Interactive form.
Regards
Trilochan -
How to set a default value in a Value Help Drop Down List
Hi,
I used an age Range field in my adobe form, the control is a Value Help Drop Down List. i am populating the drop down using following code.
IWDAttributeInfo ageInfo = wdContext.nodePersonalData().getNodeInfo().getAttribute("CTAgeRange");
ISimpleTypeModifiable ageType = ageInfo.getModifiableSimpleType();
IModifiableSimpleValueSet ageValueSet = ageType.getSVServices().getModifiableSimpleValueSet();
ageValueSet.put("1","21-29");
ageValueSet.put("2","30-34");
ageValueSet.put("3","35 or Above");
My requirement is to set a default value e.g. 30-34 in the age range field.
I want to give input to iform from my Implementation code only.
Please help.
Thanks in advancehi Ranjan,
that means you have to set at design time,
to set default drop down value you will have to set the value for particular attribute (which is linked to the dropdown element) in the context
like
wdContext.currentContext<nodeName>Element.set<FieldName>(<default value>)
This generally done in Initialization method of the controller. -
Using getElementById() to get values from drop down list
Hi, I am using Netbeans to write this program. I have this .java page that gets the url of the HtmlPage from the .properties page. And when this page is opened in the browser, there are drop down lists that have values I want to get from the user when he/she has selected, and save it to a database. I'm actually using mozilla firefox to open this page, and using firebug to inspect the drop down list element.
I know getElementById is a javascript code, however, my friend told me to use it in the .java page. This is how part of my code looks like. What I'm not sure is how to implement getElementById() and where.
HtmlPage pageMain =EBPage;
WebRequest postRequestSettings = new WebRequest(
new URL(getProperties("trustAdmin")), HttpMethod.POST);
*// Set the request parameters*
postRequestSettings.setRequestParameters(new ArrayList());
postRequestSettings.getRequestParameters().add(new NameValuePair("component", "edit"));
postRequestSettings.getRequestParameters().add(new NameValuePair("formids", "unixTime,instance,time,description,message"));
postRequestSettings.getRequestParameters().add(new NameValuePair("page", "Status"));
postRequestSettings.getRequestParameters().add(new NameValuePair("service", "direct"));
postRequestSettings.getRequestParameters().add(new NameValuePair("session", "T"));
postRequestSettings.getRequestParameters().add(new NameValuePair("submitmode", "submit"));
postRequestSettings.getRequestParameters().add(new NameValuePair("submitname", ""));
*// Insert instance of message here*
postRequestSettings.getRequestParameters().add(new NameValuePair("instance", instance));
*// Insert content of message here*
postRequestSettings.getRequestParameters().add(new NameValuePair("message", message));
*// Insert description of message here*
postRequestSettings.getRequestParameters().add(new NameValuePair("description", description));
*// Insert time of message here*
postRequestSettings.getRequestParameters().add(new NameValuePair("time", time));
*// Convert time to unix seconds*
postRequestSettings.getRequestParameters().add(new NameValuePair("unixTime", String.valueOf(System.currentTimeMillis() / 1000)));
HtmlPage newPage1 = pageMain.getWebClient().getPage(postRequestSettings);
WebRequest requestSettings = new WebRequest(
new URL("http://www.google.com"), HttpMethod.GET);
requestSettings.setRequestParameters(new ArrayList());
requestSettings.getRequestParameters().add(new NameValuePair("page", "Preview"));
requestSettings.getRequestParameters().add(new NameValuePair("service", "page"));
newPage1 = newPage1.getWebClient().getPage(requestSettings);
And I'm told to insert page.getElementById() in the place shown below:
HtmlPage page = null;
page.getElementById()_
*try {*
*// Login proxy*
page = (HtmlPage) jsonBrowser.getPage(getProperties("jsonBrowser"));
String proxyUrl = page.getForms().get(0).getAttribute("action");
System.out.println("Proxy Url" + proxyUrl);
WebRequest requestSettings = new WebRequest(
new URL(proxyUrl), HttpMethod.POST);
requestSettings.setRequestParameters(new ArrayList());
requestSettings.getRequestParameters().add(new NameValuePair("PROXY_SG_PASSWORD", password));
requestSettings.getRequestParameters().add(new NameValuePair("PROXY_SG_PRIVATE_CHALLENGE_STATE", ""));
requestSettings.getRequestParameters().add(new NameValuePair("PROXY_SG_REQUEST_ID", ""));
requestSettings.getRequestParameters().add(new NameValuePair("PROXY_SG_USERNAME", userID));
*// Get the page*
page = page.getWebClient().getPage(requestSettings);
Logger.getLogger(postTrustMessage.class.getName()).log(Level.INFO, "===================================Login in Trust");
Logger.getLogger(postTrustMessage.class.getName()).log(Level.INFO, page.getWebResponse().getContentAsString());
*} catch (IOException ex) {*
Logger.getLogger(postTrustMessage.class.getName()).log(Level.SEVERE, null, ex);
*} catch (FailingHttpStatusCodeException ex) {*
Logger.getLogger(postTrustMessage.class.getName()).log(Level.SEVERE, null, ex);
return page;
Any help would be greatly appreciated. Thanks.I want to value drop down list from seeded page of EBSString picklistvalue = pageContext.getParameter("PickListBeanID"); //PickListBeanID is the ID of the MessageChoiceBean
Thanks
--Anil
http://oracleanil.blogspot.com/ -
To pass the selected data to a variable from the drop down list in abap wd
Hi,
I have already created a drop down list and populated it with data from table by using the node and linking it with the internal table. Now I need to know which element is selected so based on that I need to perform some function. eg. based on the selected data , i need to populate the next drop down list.
A demo code will be really helpful.
Thanks and Regards
TenzinHi,
On selcting the value from the drop down, we have one event ONSELECT.
Write the code in this event.
Get the attribute value to lV_xxxxxx using get attribute.
then using that you can fill the next DDBK attribute.
method wddoinit .
data:
lo_nd_spfli type ref to if_wd_context_node,
lo_el_spfli type ref to if_wd_context_element,
ls_spfli type wd_this->element_spfli.
data:
lv_carrid LIKE ls_sflight-carrid,
itab_carrid type wd_this->elements_spfli,
wa_carrid type wd_this->element_spfli,
lo_nodeinfo_spfli type ref to if_wd_context_node_info,
lt_value_set type wdy_key_value_table,
ls_value_set type wdy_key_value.
lo_nd_spfli = wd_context->get_child_node( name = wd_this->wdctx_spfli ).
lo_nodeinfo_spfli = lo_nd_spfli->get_node_info( ).
select carrid
from spfli
into corresponding fields of table itab_carrid.
if sy-subrc = 0.
sort itab_carrid by carrid.
delete adjacent duplicates from itab_carrid comparing carrid.
endif.
loop at itab_carrid into wa_carrid.
ls_value_set-key = wa_carrid-carrid.
ls_value_set-value = wa_carrid-carrid.
append ls_value_set to lt_value_set.
endloop.
lo_nodeinfo_spfli->set_attribute_value_set( name = 'CARRID'
value_set = lt_value_set ).
endmethod.
in the event of first DDBK, write the select statement wsing where condition of lv_XXX.
and append the record as above.
Regards,
sarath -
Preselected values in drop-down lists
Hi everyone,
Some quick background before stating the issue: I've
developed a set of forms in ASP.NET working with a SQL Server 2000
db where my client can add, edit, and search records within their
intranet. When adding a record, they are making some selections
from a drop-down list where the values are dynamically populated
from a lookup table. There are three sections to the form and each
section gets its values from a different table. When editing a
record, the drop-down lists should show all the choices but
prepopulate the list with their earlier selection.
Here's the issue: everything is working just fine on my box
and is working 90% on my client's server. The problem is that when
editing a record, two of the three sections of the form are showing
the correct values. The third section is showing the first choice
in the drop-down list rather than what was recorded in the db.
Again, this is not happening in my development environment.
It's only happening on my client's environment. I've triple-checked
the code and confirmed that the datatypes in their tables match
what I've got set up in my db. The fact that these pages are behind
my client's firewall make the usual trial and error kind of
troubleshooting very difficult.
This is very mysterious. Any suggestions for what I can check
and how I can troubleshoot this?
Thanks.In case anyone else comes across this problem, it seems that
deleting and recreating the table solved the problem. I renamed the
original table and compared it to the one I recreated and they
appear to be identical but nevertheless that was the
solution. -
How to add a interactive drop-down list
I want a drop-down list that will add a set of required fields based on the choice from the list.
In this case, we want users to fill in their job title, and based on that title selected we need them to fill in specific licensing information. I haven't found a javascript (or I don't have the expertise) to make this happen. I have done forms in the past that would just hide unneeded fields, but is there a way to actually have the fields become active, or appear based on the list selections?Yes, it's possible. The general code would be something like this (as the drop-down field's custom validation script):
var field1 = this.getField("FieldName1");
var field2 = this.getField("FieldName2");
var field3 = this.getField("FieldName3");
if (event.value=="Value1") { // Show field1, hide the rest
field1.display = display.visible;
field2.display = display.hidden;
field3.display = display.hidden;
} else if (event.value=="Value2") { // Show field1 and field2, hide the rest
field1.display = display.visible;
field2.display = display.visible;
field3.display = display.hidden;
} else if (event.value=="Value3") { // Show all fields
field1.display = display.visible;
field2.display = display.visible;
field3.display = display.visible;
} else { // hide all fields
field1.display = display.hidden;
field2.display = display.hidden;
field3.display = display.hidden;
PS. Make sure you tick the option to commit the selected value of the drop-down field immediately (under the field's Properties - Options). -
Passing database table values to drop down list list using "vrm_set_values"
DEar Experts,
How can we pass database travel to drop down list using vrm_set_value call function.
Looking forward for advise from you experts .
REgards
CHandanDear Anubhab,
Thanks for your suggestion,
Plz see my code:
Type-pools: vrm.
DATA: it_zlt_mita TYPE STANDARD TABLE OF Zlt_mita,
wa_zlt_mita TYPE zlt_mita,
it_vrm TYPE vrm_values with header line .
Selection-Screen: Begin of Block b1 With Frame Title text-001.
Parameters:
p_mitar Type Zlt_mita-M1 as listbox visible length 20 user-command zcc01 obligatory,
p_mitarn Type Zlt_mita-M2.
Selection-Screen : End of Block b1.
AT SELECTION-SCREEN OUTPUT.
Select * From ZLT_mita INTO CORRESPONDING FIELDS OF TABLE it_zlt_mita.
LOOP at it_zlt_mita into wa_zlt_mita.
it_vrm-key = wa_zlt_mita-m2.
it_vrm-text = wa_zlt_mita-m1.
APPEND it_vrm.
Clear: it_vrm, wa_zlt_mita.
ENDLOOP.
CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
id = 'P_mitar'
values = it_vrm[]
* EXCEPTIONS
* ID_ILLEGAL_NAME = 1
* OTHERS = 2
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Data: dynfields type table of dynpread with header line.
dynfields-fieldname = 'p_mitar'.
Append dynfields.
CALL FUNCTION 'DYNP_VALUES_READ'
EXPORTING
dyname = sy-cprog
dynumb = 1000 " can I use sy-dynnr here
* TRANSLATE_TO_UPPER = ' '
* REQUEST = ' '
* PERFORM_CONVERSION_EXITS = ' '
* PERFORM_INPUT_CONVERSION = ' '
* DETERMINE_LOOP_INDEX = ' '
* START_SEARCH_IN_CURRENT_SCREEN = ' '
* START_SEARCH_IN_MAIN_SCREEN = ' '
* START_SEARCH_IN_STACKED_SCREEN = ' '
* START_SEARCH_ON_SCR_STACKPOS = ' '
* SEARCH_OWN_SUBSCREENS_FIRST = ' '
* SEARCHPATH_OF_SUBSCREEN_AREAS = ' '
tables
dynpfields = dynfields
* EXCEPTIONS
* INVALID_ABAPWORKAREA = 1
* INVALID_DYNPROFIELD = 2
* INVALID_DYNPRONAME = 3
* INVALID_DYNPRONUMMER = 4
* INVALID_REQUEST = 5
* NO_FIELDDESCRIPTION = 6
* INVALID_PARAMETER = 7
* UNDEFIND_ERROR = 8
* DOUBLE_CONVERSION = 9
* STEPL_NOT_FOUND = 10
* OTHERS = 11
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'DYNP_VALUES_UPDATE'
EXPORTING
dyname = sy-cprog
dynumb = 1000
tables
dynpfields = dynfields
* EXCEPTIONS
* INVALID_ABAPWORKAREA = 1
* INVALID_DYNPROFIELD = 2
* INVALID_DYNPRONAME = 3
* INVALID_DYNPRONUMMER = 4
* INVALID_REQUEST = 5
* NO_FIELDDESCRIPTION = 6
* UNDEFIND_ERROR = 7
* OTHERS = 8
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
PLZ SUGGEST ME IF ANYWHERE I WENT WRONG IN MY CONCEPT AS PER YOUR SUGGESTION.
Looking forward for your further guidance.
Regards
Chandan -
Restricting the values in Drop Down list for ESS application
Hello Experts,
We are trying to restrict the values in the drop down list box for payment method field for direct deposit iview.
Here Payment is the Zlsch field.
here we are trying to have only 3 vlaues in the drop down. Do I have to do it from java code or can this be restricted on the ECC side?
Plese let me know.
Thanks,
James.James,
What you have to do is create a DropDown ByIndex element instead of by Key and create a context node PaymentMethodNode and a value attribute PaymentAttribute under it ....then write the following code in the wdDoInit() method as :
//Add whatever values you want in the DropDown
String[] priority_options= new String[]{"Payroll/Corp/Partner Check","Employee Payroll ACH(PPD)"};
List ListOfPriorities = new ArrayList();
for(int i=0;i<priority_options.length;i++)
IPrivateDetailView.IPayment_MethodNodeElement pr= wdContext.createPayment_MethodNodeElement();
pr.setPaymentAttribute(priority_options<i>);
ListOfPriorities.add(pr);
wdContext.nodePayment_MethodNode().bind(ListOfPriorities);
for(int e=0;e<wdContext.nodePayment_MethodNode().size();++e)
wdContext.nodePayment_MethodNode().setSelected(e,e>=0 && e<=1);
and then write the following code in wdDoModifyView() method:
IWDDropDownByIndex di =(IWDDropDownByIndex)view.getElement("DropDownByIndex");
di.bindTexts("Payment_MethodNode.PaymentAttribute");
then create an Action and bind it to the onselect property of the DropDown and write the following code in the onAction method :
if(wdContext.currentPayment_MethodNodeElement().getPaymentAttribute().equalsIgnoreCase("Payroll/Corp/Partner Check"))
wdContext.currentSelectedInfotypeElement().setZlsch("C");
else
wdContext.currentSelectedInfotypeElement().setZlsch("P");
I am sure it will work.. -
Change values of drop down list when other drop-down list value is clicked
Hi Gurus,
I look for my requirement very much but I can't find. I think it must be very simple but I can't do it, please help :
I have to custom added fields. Both of them is made drop-down list by picklist defined in GET_P...methods.
When I click and select a value from the first drop-down list, I want that second drop-down values are fully changed, depend on what I select in the first list. If I select my value and press enter in the first drop down box, I can do my requirement with GET_V...method. But if I don't press enter, the values of second list doesn't change, they remain same. I want exactly that when I click and select a value from first drop-down list, second drop-down list values are automatically change, dependent on what selected. Do I have to define and event?? where and how, please help me..Hi,
You must have created the field as a dropdown using the below code in the get_p method.
CASE iv_property.
WHEN if_bsp_wd_model_setter_getter~fp_fieldtype.
rv_value = cl_bsp_dlc_view_descriptor=>field_type_picklist.
ENDCASE.
Here you need to add the below lines of code along with the previous code. for the first dropdown value
IF iv_property = if_bsp_wd_model_setter_getter=>fp_server_event.
rv_value = 'DDLB_CLICK'.
ENDIF.
This would refresh the screen when the user selects any value from the dropdown.
Regards,
Radhika -
Hi,
in my ssrs report i have two parameters, accounts and Manager ,there is a cascading between the accounts parameter and manager parameter, as per the cascading we will get managers names based on the account we selected in the accounts parameter,
my requirement is the first name in the mangers drop down list has to get selected as default value.
please help me with this, it is an urgent requirement.
Thanks in advance,
NaveenHi NaveenMSBI,
According to your description, you want to use cascading parameters in the report, if the accounts are selected when you preview the report, the first manager name will be selected from drop down list as the default value. If so, there can be two scenarios:
• If manager is single-valued parameter, we can get Available Values and Default Values from the same query as below. Then when the accounts are selected, the first manager name will be selected as default value.
SELECT managerName FROM table_name WHERE accounts IN (@accounts)
• If manager is multi-valued parameter, we need to use different query for Available Values and Default Values. In this case, please refer to Patrick’s solution.
For more information about Adding Cascading Parameters, please refer to the following document:
http://technet.microsoft.com/en-us/library/aa337498(v=sql.105).aspx
If you have any questions, please feel free to let me know.
Best Regards,
Wendy Fu -
Setting values in Drop down list in Screen Painter
Hello Freinds,
I have the requirement as, I have drop down list in screen painter and want to fill the values in that list using database table.
So using foreign key table I have updated the values in the list.
But now client wants me to fill the dropdown list with ID as well as description..
Please suggest me how to achieve this.
Thanks and Regards
NishadHi,
You the FM 'F4IF_INT_TABLE_VALUE_REQUEST' and try.
Fill the internal table with the key and description and pass the same to above FM.
You will get sample code by searching the forum.
Thanks.
Anversha -
Please help: Populating values in drop down list by onchange - javascript !
I am working on a task - I need to populate drop down named "year" dynamically (from database) depending upon the select of an element from drop down list "carLine" . I am calling javascript funtion on onchange event of the html select and setting property of the selected element.The environment is Struts and dynaactionform is being used . Here is the my html select for both the drop down list s and javascript funtion to set value. The getYears method is defined in the locatoraction action class. But after doing all these carLine is not getting populated with the values corresponding to selected carline.
Database side is working fine .
<script type="text/javascript">
function getYearsForCarline(){
document.getElementById('method').value = 'getYears';
document.forms[0].submit();
alert("submitted");
</script>
<html:form styleId="locatorForm" action="/locator/locatorAction" method="post">
<input type="hidden" name="method" value="getYears" />
<tr>
<td align="center">
<table border="0" width="300" cellpadding="0" cellspacing="5">
<tr>
<td><span class="formLabelEM"><bean:message
key="label.locator.carLine" />*</span>
<html:select styleId="carLineBox" property="carLine" onchange="javascript:getYearsForCarline()">
<html:option value="">Select a Carline</html:option>
<html:optionsCollection property="carLines" />
</html:select></td>
</tr>
<tr>
<td><span class="formLabelEM"><bean:message
key="label.locator.modelYear" />*</span>
<html:select property="year" >
<html:option value="">Select Year</html:option>
<html:optionsCollection property="years" />
Any advise will be highly appreciated . Thanks in advance.Thanks both of you for the advise ! My code worked perfectly fine after adding separate action mapping for Year and using that as action in the form though the new action mapping point to the same action class locatorAction ..I still do not understand the reason behind this exactly(any suggestion are most welcome) but it works. Here is code for my action mapping :
<action path="/locator/locatorYearAction" name="locatorForm"
input="/locator/locatorMain.jsp"
type="com.apps.sales.web.salesin.actions.LocatorAction"
parameter="method" validate="true">
<forward name="showCarlines" path="/locator/locatorMain.jsp"
redirect="false" />
<forward name="showModels" path="/locator/locatorModels.jsp"
redirect="false" />
</action>
Maybe you are looking for
-
Hey, I have been testing my applications I have written in java since Windows 7 RC's had first started being released. Finally after installing the retail ultimate edition... the results from Java GUI related stuff is still as it was since Windows 7'
-
How do I recapture purchased and downloaded music for my I Tunes library after inadvertently deleating that info?
-
Gallery for non .mac?
Is Web gallery even an option for non .mac domains? I host my personal website on godaddy and am wondering if the coolness that is the new Web .mac gallery can be "published" to godaddy.
-
I want to use GETRIGHT software to download Oracle 8i personal edition for windows 98. This software ask for URL address for downloading file. Can you give me URL address for downloading ORacle 8i personal edition for windows 98.
-
Can I build in then build out before building in next bullet?
I cannot figure out how to build in a bullet then build out said bullet before adding next bullet.