Show or Hide fields based upon a variable value
Hi,
I am a rookie in the field of Acrobat. And my only question is :
How to Circle a Form Field based upon a variable value .
For example, If x=1, I want to circle Japan and if x=0, I want to leave it without any change.
Please help me out. Thanks for your time and help.
Thanks,
Vijayvijay77.
Hi George,
I am pre-populating a Pdf file based upon the data submitted by the user. And I have to circle options selected in the form.
I am writing coldfusion code to flatten, populate the form into a PDF form. The end result is the PDF generation with all the data in it.
The data comes from the database, where I set variable values if any is selected or not.
Thanks for your reply, I really appreciate your help.
Vijayvijay77.
Similar Messages
-
MultiLookup items selected, show or hide fields dynamically
Hi,
In the New or Edit Form, I would like to show or hide fields based on the multiselect value selected.
Is there a way to add javascript to achieve this and to get the selected values to show or hide the fields dynamically?
Thanks for your help.Hi,
According to your post, my understanding is that you want to show or hide fields based on the multiselect value selected.
You can add the code below to the new form.
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script type="text/javascript">
function Test(){
var object= $("select[title='Lookup selected values']");
var object1=$("input[title='Test']");
var text= object.find("option").text();
alert(text);
if(text.indexOf("A")>-1)
object1.hide();
</script>
<button onclick="javascript:Test();" type="button">Test</button>
Note: You need to change the title of the select and input tags.
The result are as below:
Best Regards,
Linda Li
Linda Li
TechNet Community Support -
Showing/Hiding certain fields based on Radioset selection
Hello all,
I'm like to know whether it is possible to Show/Hide certain fields using a RadioSet selection as it is done in Forms in ADF UIX. Kindly go through this post.
Showing/Hiding certain fields based on Radio Group selection
kindly help me out on this.
Thanks & Regards,
Arun.VHi Arun,
Here is what I do with my checkboxes, but I think that the radiobutton will do the same:
<af:selectBooleanCheckbox text="selectBooleanCheckbox 1"
label="Label 1"
binding="#{backing_page1.selectBooleanCheckbox1}"
id="selectBooleanCheckbox1"
autoSubmit="true"
immediate="true"/>
<af:inputText label="Label 1" binding="#{backing_page1.inputText1}"
id="inputText1"
disabled="#{!backing_page1.selectBooleanCheckbox1.selected}"
partialTriggers="selectBooleanCheckbox1"
value="#{backing_page1.selectBooleanCheckbox1.selected}"/> -
Selectively executing a mapping rule based on a variable value
Hi,
I have written a mapping rule in the following format.
case #time_unit when 'quarter' then
logic1
when 'month' then
logic2
end
In logic1, logic2 i again have nested case statements. Variable time_unit will have a static value hard-coded given (quarter/month) by user before execution.
So Variable time_unit need not be checked for each row that gets transformed. It hits the performance.
I want either logic1 or logic2 to be substituted dynamically in the mapping rule window based on the variable value.
I cannot go for 2 seperate interfaces. How can I achieve this in ODI.
Please help me.
Thanks!!Sarah,
I'm not aware of doing other than BPM. If you want the BPM Steps, Please refer below
Step 1 : Receive
Step 2 : Transformation
Step 3 : Send (Syncronous call to the target system)
Step 4 : Switch(Check the Payload value as per your reqmt)
Step 5 : Transformation(Switch : False ,If the payload value is not ERROR)
Step 6 : What you wanna do ( Switch :True)
If you want more technically, then let me know the source and target systems, I will help you to design
the complete flow.
Best Regards,
raj. -
Looping thru column names based on a variable value
I have an ArrayCollection with a series of columns named
price1, price2... thru to price10
I'm trying to loop thru these columns based on a variable
value, but can't figure the syntax:
for (var column:int = 1; column < 11; column++){
testPrice = myGrid.selectedItem.price(column); <-- this
doesn't work
}Try testPrice = myGrid.selectedItem["price" + column];
Remember to test that selectedItem isn't null before you try
to assign the values.
TS -
APEX 4.1 show hide fields based on value of checkbox/radio
I am trying to successfully hide and show fields based on the value of a clicked checkbox. I am using a dynamic action, but it isn't working.
I followed the sample at Does Oracle Apex 4 enable the following AJAX features? (ie without the dev writing the Javascript) - Stack Overflow
I even tried a radio button, but it didn't work. I cannot uncheck the radio button. What am I doing wrong? Thank you for any help you can provide.Hi,
create a dynamic action for page load to hide the item which you wanna hide
now create another dynamic action
event : Click
Selection Type : Items
Items : P1_Check_box(name of the check box item)
condition : equal to
value : return value of the check box item (if you click the check box and the return value is 1 then just add 1)
in true actions
Action : Show
Selection Type : Items
Items : P1_Text_field(name of the field)
uncheck fire on page load
create exact opposite false action, that's it.
Regards,
Mohan. -
Reading T588M hide fields for MOLGA/feature/variable key & HIDE custom flds
Hi
I have requirement to read hide fields from T588M . As we can hide filed in T588m and we already have written a program in which it called certain feature from PE03 for IT0002 and hide the filed based on the user authorization . Now I have introduce another field which some how the same as in SAP standard screen , for some good reason and according to business process it was not full filling the requirements . So I introduce another field. Now what we want in PBO of IT enhancement it stop certain users to see that fields using feature ( Tr.Pe03 Feature p0002 ) . In feature we have programmed that it call our customized program and check the authorization as mention earlier .
Herere my questions
- Do you guys have any other good option to control that?
- If some how I manage to read feature using FM HR_FEATURE_BACKFIELD in PBO
- After reading feature I am accessing the table T588m to make sure for certain feature which field is hide or not as in table T588m I can see the fields like +-, , how can I make sure which field is refer to what I also find the FMS
- HRPAD00SCREENCONTROL
- HR_READ_T588M_WITH_PME04
- HR_T588M_CUSTOMIZING
- HR_T588M_GET_DYNPRO
- HR_T588M_GET_FIELDATTRIBUTES
- HR_T588M_SAVE
- But the above Fm also not fulfilling my requirement. As I was thinking that I read the fields , SAY if standard field is hide in the feature , I can loop at my screen and hide the custom field which I enhanced in IT0002.
Right now Im debugging the standard code how its reads the T558M , and I got some clue .. But it looks like long path I mean reading some screen fields.. Include program is L0PXVF01 .
Now my question is do you guys have any good solution, it might possible Im doing it using the short path .. ( Cuz I wna use my security program as its using feature )
Let me know if u have some idea
Thanks
Saquib Khan1- Well Im thinking that I have to compare T558M on the base of Feature and variable key . And see that standard field is hidden... if it is .. I want to also HIDE my custom field ....
2- For our feature "p0002" , we have developed a custom code in which on the basis of variable key and user profile it get executed and also see wther that person has authorization to see that standard field or not . if say that person doesnt have authorization for that field I can also hide mine custom field.
I just got the test login and Im going to test it by add/removing security roles .
<b>
I tried that out but if Im looping at screen , its behaving same for both users . Cuz there is nothing which tells ok for this user fild is hidden in T558m and its open for other one..
Also, is there any FM if I pass Dynpro # , molga and variable key , it return me T588M hidden fields ...
I already tried the above FM
This looks like to work but not working for field
HR_T588M_GET_FIELDATTRIBUTES</b>
Thanks for valuable input!!
Saquib -
Show or Hide Items based on radio value
I am trying to show and hide various Items based on the values of a radio button item. I have see the code and examples like
function Show_On_Radio_Value(pThis, pThat, pValue){
var rv = html_RadioValue(pThis);
if (rv == pValue) {
html_ShowItemRow(pThat);
} else {
html_HideItemRow(pThat);
The problem I am having is that I have 3 different values of the radio item and I want to display certain items based on each different value.
For example:
radio_value = 'Yes'
Show Item1, Item3, Item4
or
radio_value = 'No'
Show Item2, Item5, Item6
or
radio_value = 'Maybe'
Show Item1, Item2, Item4
I am fairly new to this so it might be easy, I just don't know how.
Any help would be appreciated.
--DGArie,
Thanks for the reply. I have tried it using the Show_On_Radio_Value function but I still can't get it to do exactly what I want. I have a working version here http://apex.oracle.com/pls/otn/f?p=25290 ,
The code I used for this demo app is:
[script language="JavaScript1.1" type="text/javascript"]
<!-- Hide
function Show_On_Radio_Value(pThis, pThat, pValue){
var rv = html_RadioValue(pThis);
if (rv == pValue) {
html_ShowItemRow(pThat);
} else {
html_HideItemRow(pThat);
function Hide_On_Radio_Value(pThis, pThat, pValue){
var rv = html_RadioValue(pThis);
if (rv == pValue) {
html_HideItemRow(pThat);
} else {
html_ShowItemRow(pThat);
// End Hide -->
[script]
In the HTML Form Element Attribute for the radio button:
onchange="Show_On_Radio_Value('P1_RADIO','P1_TEXTAREA','Maybe');
Hide_On_Radio_Value('P1_RADIO','P1_TEXTFIELD1','Maybe');
Hide_On_Radio_Value('P1_RADIO','P1_TEXTFIELD2','Maybe');
Hide_On_Radio_Value('P1_RADIO','P1_TEXTFIELD3','Maybe');
Hide_On_Radio_Value('P1_RADIO','P1_TEXTFIELD4','Maybe');
Hide_On_Radio_Value('P1_RADIO','P1_RADIOBUTTON','Maybe');
Hide_On_Radio_Value('P1_RADIO','P1_TEXTFIELD2','No');
Hide_On_Radio_Value('P1_RADIO','P1_TEXTFIELD4','No');
Hide_On_Radio_Value('P1_RADIO','P1_RADIOBUTTON','No');
The problem I see is that in the onchange event, the 'No' options are working because they appear last in the event.
Can you possibly provide an example using a Case statement?
Thanks,
DG -
PM Notification - Hide fields based on other field's value
Hello experts,
I am looking for an user exit which allows me to hide some fields based on other field's value.
For example, I have field 1 and field 2. When I open my notification, if the value of field 2 is 'aaa', field 1 has to be hidden.
There should be an user exit but I can't find it...
Thanks for your help!Hi everyone,
Any thoughts? any help is appreciated...
Thanks -
Data Selection for report based upon a 'Prompt Value'
I want to report information in my report based upon a 'user input prompt value'
for example:
'Enter Shareholder Selection - A-Active, I-Inactive, B-Both Active and Inactive'
if the user enters 'A', the report selects only active shareholders
if the user enters 'I', the report selects only inactive shareholders
if the user enters 'B' the report selects all shareholders, active and inactive
the field in the database that this based upon is their total share value.
if this field is greater than zero (>0) they are considerd 'active'
if this field is equal to zero (=0) they are considered 'inactive'.
I have tried creating some type of filter, but am not having any luck.
I saw a few examples within the forums that I have tried without any luck....unfortunately most of the examples I've seen are base one only two choices.
I'm sure I need to create some type of 'independant varible' but am not sure how to do that either.
Any suggestions would be appreciated.
Thanks.Hi Daryl,
I Tried this unsuccessfully in DESKI . We can't Eliminate Rows having Empty Measure Values or Measure with 0 as values using Table Level Filter as FIlter can't FIlter rows based on Prompt value selection dynamically. Filters filter rows at a time and not based on 3 condition as Active, Inactive and Both. thus filters are of no use.
I Tried this in WEBI, and it is working perfectly you donu2019t have to create any Object in Universe, you can do it using function UserResponse() at report level.
Hence if you are comfortable using WEBI for Generating this report then Follow the steps.
1. Create Report With Name and Shares Object. It will display all Shareholder Names and No.of shares they hold.
2. Use Status Object in Query filter, use condition as u201CEqual Tou201D and Select prompt. It contains Active, Inactive and Both as values.
3. Report will Display all Shareholder names and No. of shares like 45, 789, 0, 4562 where 0 is inactive Shareholder and all other are active shareholder.
4. Create Variable using Formula.
=If(UserResponse("Enter Status:")="Active" And [Shares]>0;[Shares];If(UserResponse("Enter Status:")="Inactive" And [Shares]<=0;[Shares];If(UserResponse("Enter Status:")="Both";[Shares])))
5. Remove Shares Object from the report and Put Variable created with Names of Shareholders.
6. Select Table-> Properties-> Display-> Uncheck the Option u201CShow Rows with Empty Measure Valuesu201D
7. Report will display Value correctly as per your Prompt value selection.
I Hope this Helpsu2026
Thanksu2026
Pratik -
Naming the evaluated case statement field with concatenating input variable value
Hi,
I am trying to add the input variable value to case statement evaluated field like below query:
declare @Year varchar(4)
select ProductCode,datepart(mm,Date) MonthValue,
case when datepart(mm,Date) = 1 then sum(Price) else 0 END AS Jan+@Year,
case when datepart(mm,Date) = 2 then sum(Price) else 0 END AS Feb+@Year,
case when datepart(mm,Date) = 3 then sum(Price) else 0 END AS Mar+@Year,
case when datepart(mm,Date) = 4 then sum(Price) else 0 END AS Apr+@Year,
case when datepart(mm,Date) = 5 then sum(Price) else 0 END AS May+@Year,
case when datepart(mm,Date) = 6 then sum(Price) else 0 END AS Jun+@Year,
case when datepart(mm,Date) = 7 then sum(Price) else 0 END AS Jul+@Year,
case when datepart(mm,Date) = 8 then sum(Price) else 0 END AS Aug+@Year,
case when datepart(mm,Date) = 9 then sum(Price) else 0 END AS Sep+@Year,
case when datepart(mm,Date) = 10 then sum(Price) else 0 END AS Oct+@Year,
case when datepart(mm,Date) = 11 then sum(Price) else 0 END AS Nov+@Year,
case when datepart(mm,Date) = 12 then sum(Price) else 0 END AS Dec+@Year
from Sales_Imports where datepart(yyyy,Date) = @Year
group by ProductCode, datepart(mm,Date)
Please help me any other way as this is not working...
Thanks,
Srinicreate table Sales_Imports (ProductCode int, Price int, [date] date)
insert into Sales_Imports values
(1,10,'1/1/2014'),(1,109,'2/1/2014'),(1,10,'1/1/2014'),(1,109,'12/1/2014'),
(2,10,'1/1/2014'),(2,109,'2/1/2014'),(2,10,'10/1/2014'),(2,109,'12/1/2014')
declare @Year varchar(4)='2014'
DECLARE @MaxCount INT, @SQL NVARCHAR(max) ,@i INT;
Set @MaxCount = 12
SET @i = 0;
SET @SQL = '';
WHILE @i < @MaxCount
BEGIN
SET @i = @i + 1;
SELECT @SQL = @Sql + ', SUM(CASE WHEN datepart(mm,[Date]) = ' + cast(@i AS NVARCHAR(10)) + ' THEN Price Else 0 END) AS ' +Left(DateName(month,Dateadd(month,@i-1,0)) ,3)+@Year
END
SET @SQL = N' SELECT ProductCode, datepart(mm,Date) MonthValue ' + @SQL
+ N' FROM Sales_Imports
where datepart(yyyy,Date) ='+ @Year + N'group by ProductCode, datepart(mm,Date)
Order by ProductCode, datepart(mm,Date)';
--PRINT @SQL;
execute (@SQL);
--Or your original one
declare @Year varchar(4)
Set @Year ='2014'
declare @SQL Nvarchar(4000)
SET @SQL=
N' select ProductCode,datepart(mm,Date) MonthValue,
case when datepart(mm,Date) = 1 then sum(Price) else 0 END AS [jan' +@year+'],
case when datepart(mm,Date) = 2 then sum(Price) else 0 END AS [feb' +@year+'],
case when datepart(mm,Date) = 3 then sum(Price) else 0 END AS [Mar'+@year+'],
case when datepart(mm,Date) = 4 then sum(Price) else 0 END AS [Apr'+@year+'],
case when datepart(mm,Date) = 5 then sum(Price) else 0 END AS [May'+@year+'],
case when datepart(mm,Date) = 6 then sum(Price) else 0 END AS [june'+@year+'],
case when datepart(mm,Date) = 7 then sum(Price) else 0 END AS [july'+@year+'],
case when datepart(mm,Date) = 8 then sum(Price) else 0 END AS [Aug'+@year+'],
case when datepart(mm,Date) = 9 then sum(Price) else 0 END AS [Sep'+@year+'],
case when datepart(mm,Date) = 10 then sum(Price) else 0 END AS [Oct'+@year+'],
case when datepart(mm,Date) = 11 then sum(Price) else 0 END AS [Nov'+@year+'],
case when datepart(mm,Date) = 12 then sum(Price) else 0 END AS [Dec'+@year+']
from Sales_Imports where datepart(yyyy,Date) = ' + @Year +N' group by ProductCode, datepart(mm,Date)'
--print @Query
Execute (@SQL)
drop table Sales_Imports -
Show / hide field based on text in another field
Hi,
I'm trying to make one of my fields reactive to what is the text generated in another field.
At the moment I have this under calculate using custom javascript:
var Mask = this.getField("Course").value;
if(Mask == 'Swimming') this.getField("Code").display = display.visible;
else this.getField("Code").display = display.hidden;
Whereas Course is the field that is changing and Code is the one that will show/hide based on content of Course.
Any help?Hi Everyone,
After doing trials with simple calculations it still wasn't working and so I've figured out what the problem is - the document was being exported but with the data being pre-populated from an SQL database in which during the export it all happens at once, not a chain effect so when the export happens it was filling "Code" before "Course" had any info in it...
The fix was basically having to create a different field in the SQL source itself for an independent field on the pdf form. -
Show/Hide fields based on choices in drop down menu
I need help with a script that I cobbled together from an example script; I'm not good enough at java to edit it for my needs.
I have a form where I would like different drop down fields would be visible/hidden depending on the choices made from other drop down menus.
If (for example) they select paper type "white" or "color" then "white" will result in a second menu of paper choices, the "color" selection result in them picking the paper wieght, then from there the color.
My problem stems from the fact that my form is very linited in space, so I would like some of these fields to be essentially on top of each other; visibility dependant on previous choices. I can get to Menu 1 (select paper color) and then Menu 2 if they select white. But there's a problem with setting up a third menu in this series, if they select "color" from Menu 1, then I try to have a drop down for paper weight, all the fields except for Menu 1 are hidden. Playing with the script let me have them all visible, but again, I'm limited on space and can't really spread them out.
I know I'm missing one small command... somewhere.
Here is the script I'm working with:
function control_section_fields() {
if (event.willCommit) return;
// Get the value selected in the combo box
var section = event.changeEx;
// Hide all of the entry fields
getField("sec").display = display.hidden;
// Reset all of the entry fields
resetForm(["sec"]);
// Display the fields for the selected section
getField("sec." + section).display = display.visible;
where the drop down fields are named "sec.a.dd" for example, and the Export value of different values are assigned as "a", "b", etc.
Sorry for the rambling. Any help will be greatly appreciated.also, if "==" could be roughly translated to "is", "!=" would mean "is not".
JavaScript is Case sensitive so make sure you did not name your field STATE#1 instead. It's a pretty common error. Try not to use special characters when naming fields. Stick to standards. I personnally always name fields with capital letters and numbers using identation like
MYFORM.PLACE.NUMBER
MYFORM.PLACE.ADDRESS
MYFORM.SEX.MALE
MYFORM.SEX.FEMALE
This is really useful if you have lots of fields related to one another. You can then apply methods to entire groups of fields in one simple line of code.
For example this.getField("MYFORM").display = display.hidden would hide all four fields. It works kind of the same way as folders unside your computer.
Finally, "#" is generally used as widget identification. I think this is what happened. If you copy a field, it retains the same name and some of its charateristics but acrobat will assign them a number called widget. The original field State will get the identification State#0 in the right pane as it is 0-based. The copie will be identified State#1. You must understand that the name of the field is still "State". Some methods (actions you can code) let you determine the widget number for targetting a specific field from those you copied. It is not the case here. So for disambiguation, you should name your fields different name like STATE1 and STATE2, or STATE.1 and STATE.2 if you plan to use what I wrote about earlier. -
Show/Hide Fields Based on Dropdown
Hi,
I am attempting to show/hide subforms with a dropdown selection. I've found a lot of information on the subject, and have ended up with this as my script:
form1.Page1.Division::exit - (JavaScript, client)
switch (Page1.Division.rawValue)
case "1":
SubformZZI.presence = "visible";
SubformZZR.presence = "hidden";
break;
case "2":
SubformZZI.presence = "hidden";
SubformZZR.presence = "visible";
break;
However, it is not doing anything when a selection is made in the dropdown box. I have the "SubformZZI" initially set as "Visible" and the "SubformZZR" initially set as "Hidden".
Any suggestions?
Regards,
ZeroZoneYou have wrongly referenced the fields in your code.
Copy and paste the below code in the click event of the Submit button. It should work as expected.
The code thathas error is commented..
// First check if there are null values, then construct email using script
var vEmail = "";
var vSubject = "";
var vBody = "Attached to this email is a Field Service Issue - Parts Order Form for Job #" + Page1.JobNumber.rawValue + ".";
var vName = "";
var vCC = "[email protected]" + "," + Page1.RSM.rawValue + "," + Page1.IssueLeaderEmail.rawValue;
var vFormat = "PDF";
var errorMessage = "At least one required field was empty. Please fill in the required fields (highlighted) before continuing.";
// Check required fields and build error message
if (Page1.IssueLeaderEmail.rawValue == null)
errorMessage = errorMessage;
else
vSubject = "Field Service Issue - Parts Order Form for Job #" + Page1.JobNumber.rawValue;
// Check Division field
if (Page1.Division.rawValue == "Case Division")
//vEmail = Page1.SendFormToZZI.rawValue;
vEmail = Page1.SubformZZI.SendFormToZZI.rawValue;
//vCC = Page1.SendCopyToZZI.rawValue + "," + Page1.CSTZZI.rawValue;
vCC = Page1.SubformZZI.SendCopyToZZI.rawValue + "," + Page1.SubformZZI.CSTZZI.rawValue;
else
//vEmail = Page1.SendFormToZZR.rawValue;
vEmail = Page1.SubformZZR.SendFormToZZR.rawValue;
//vCC = Page1.SendCopyToZZR.rawValue + "," + Page1.CSTZZR.rawValue;
vCC = Page1.SubformZZR.SendCopyToZZR.rawValue + "," + Page1.SubformZZR.CSTZZR.rawValue;
// If fields required for script are null, warn user and do not initiate email
if (Page1.IssueLeaderEmail.rawValue == null)
xfa.host.messageBox(errorMessage, "Sending an email", 0, 0); // Send out a custom error message if any of these fields are null
else
// Everything is OK, send email
event.target.submitForm({cURL:"mailto: "+ vEmail +"?subject=" + vSubject +"&body=" + vBody + "&cc=" + vCC,cSubmitAs:"PDF",cCharset:"utf-8"});
Thanks
Srini -
Hide field based in process type - GS_CM Component
Hello.
Currently, we need to hide a field in GS_CM/AddDoc view of component GS_CM, because it have to be based on process_type.
In CMBO node context, we have the object_type of the transaction (TYPEID attribute), but we need the process type to evaluate to hide the field.
Please, help.
Regards,
Renzo.Hello!!
Problem solved!
We apply the changes indicated in this link:
http://scn.sap.com/community/crm/webclient-ui-framework/blog/2013/05/13/accessing-component-controller-or-custom-controller-in-a-context-node-class
Then, we can obtain the guid of the operation and use the FM CRM_ORDER_READ_OW for read in memory the process type of the operation .
Thanks!
Regards,
Renzo.
Maybe you are looking for
-
Sending video OUT via Firewire to my Camcorder FROM my computer?
Hi all! Can I send video OUT from my comp. to my camcorder via Firewire. I have a camcorder that has Passthrough to use it as a bridge which I have used to hook up a vcr with. But Im not sure if I can send video OUT to the camcorder and record it on
-
How to use deployment priorities during background TLB automatically
Hi All, In standard functionalitiy, deployment split results are not considered during backgroung / interactive TLB automatically. Wanted to know if there any custom way (BADI / FM) to use the deployment priorities in the back ground or interactive T
-
Solaris 9 installation "misleads" into mount drives-error -- please help -
hi out there - masters of the using of Solaris 9 ... whenever I try to install the program onto any harddisk after loading drivers the installation program tells me that not even one of the harddisks can be mounted ... well I have 3 harddisks & 1 com
-
Musicdock app has stopped working. Will say buffering and then stop. Anyone know what to do? Or another app to use. Sirius app times out.
-
Activity Data Collector Log Analysis
Hi Experts, Is it only me who wonders about how to analze the ADC Logs? Isn't there any standart tool, method to analyze it? The product desc. says you can export to excel or, BI to analze but isn't there any standart way to do it with standart log c