Display required field based on LOV

I have an application that has many required fields. One of the fields (P11_RANK) is populated from a LOV. I have a condition on this field when a specific item(s) is selected form the LOV, (:P11_RANK IN ('First-Year Student','Sophomore','Junior','Senior') an additional required field (P11_FACULTY_SPONSOR) is displayed on the form.
Currently my application is working but the additional required field to be display and filled in does NOT display until after the SUBMIT button is pressed. The applicaiton user needs to fill in this addtional field and SUBMIT again. As you can imagine that causes a bit of confusion, even though I have explained this quirk in my application notes.
I would like the field to display after I leave the RANK field. I think this is where javascript comes in, but I am new to javascript and the training I received did not cover this issue. I have looked at Carl Backstrom's examples, but I am still confused as to what needs to be done.
Any help on this would be greatly appreciated.
Joyce

I found a simple workarround and I will post it:
1. Instead of using LOV I created a function that does the same
( using a cursor and returning a value )
2. Since the field needed to act as a link, I used css to format the output
and it worked just fine.
Thanks,
Denes Kubicek

Similar Messages

  • Display as text (based on LOV saves state) : possible border ?

    Hi,
    Like mentioned in the subject, I have many Display as text (based on LOV saves state). I would like to have a frame or a border around this field eventhough it's read only, like a regular field. How can I do that ?
    thank you.

    Depending on your visual requirements, you could change the items to Text Fields (disabled or not) then simply make the Read-Only atttribute set to "always" or something that would equate to "always". It would look just like a text field (since it would in fact be one), but would be read-only.
    Sadly, this would require you to change all your items to the new type which would take time.

  • Where is "Display as Text (based on LOV, saves state)"

    I am developing an application using the version of HTMLDB that comes with OracleXE.
    I have a tabular form, in which the default column for a particular item is sourced from a previously entered item on another page. This is a lookup item and needs to be non-changeable by the user. So I want to use the "Display As" option "Display as Text (based on LOV, saves state)". However, this option is not available in the pull-down for "Display As". The option "Display as Text (based on LOV, does not save state)" is available, but using this option means that the item is not saved to the database.
    Does anyone know why the stateful display as option is not available.
    Thanks in advance,
    Rob

    Scott, thanks for the feedback. The problem is that although the value is displayed correctly, it is NOT saved to the database. Effectively, header information is entered in a previous screen, and one of the entered fields is written to each of the detail lines associated with the header. We are re-platforming an existing application (written in an obscure form of basic), and at this stage changing the schema is not an option. So this header item (which is a foreign key to a "store" table), is meant to be written down to each line, on the screen displayed as the store name, and written to the inserted lines as the lookup id. If I use the dispaly as text save state option teh database is updated correctly, but displays the id rather than name on the screen. The only display as lov option i can see is the one that does not save state. If I use this option the screen displays as I want but the database is not updated. I need to use the display as lov saves state option. but i do not see it.
    Any ideas?
    Thanks for your time.
    Rob

  • Annoying [ ] with "Display as Text (based on LOV, saves state)"

    Hi all,
    I've got a form where some items are shown as “Display as Text”. These values are displayed normally.
    But I also have some items which are shown as “Display as Text (based on LOV, saves state)”. When I run the page and these items don't return a value (because it isn't filled in in another page), we get the annoying []-sings.
    Is there anyone who knows how to fix this, I just want to display nothing when there is no value.

    I've tried this one already.
    I tried to leave it blank, & nbsp ; , text,... but the problem is that our lov is build by a function and it always returns a query, so the LOV is never null.
    I figured something out: made a process after header that has some cursors to get the values from the database and changed the item to a simple display as text-field. There were only 4 that were wrong, so it wasn't to much work.

  • Display As Text (based on LOV, saves state)  "p_t03" was assigned by APEX

    Hi All,
    I have an ITEM
    Name: P36_INT
    Display As: Display As Text (based on LOV, saves state)
    Output in my HTML:
    [input type="hidden" name="p_t03" value="YES" />[span id="P36_INT">Interior[/span>
      'p_t03' was assigned by APEX
      In my Javascript I have to access it as the following to get the "YES" value:
      var lintObj = html_GetElement('p_t03');
      Originally it was 'p_t01' but it changed from 'p_t01' to 'p_t03' somehow.. out of my control.
      How do I assign an ID or assign my own name to the "hidden" item?                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    Scott, thanks for the feedback. The problem is that although the value is displayed correctly, it is NOT saved to the database. Effectively, header information is entered in a previous screen, and one of the entered fields is written to each of the detail lines associated with the header. We are re-platforming an existing application (written in an obscure form of basic), and at this stage changing the schema is not an option. So this header item (which is a foreign key to a "store" table), is meant to be written down to each line, on the screen displayed as the store name, and written to the inserted lines as the lookup id. If I use the dispaly as text save state option teh database is updated correctly, but displays the id rather than name on the screen. The only display as lov option i can see is the one that does not save state. If I use this option the screen displays as I want but the database is not updated. I need to use the display as lov saves state option. but i do not see it.
    Any ideas?
    Thanks for your time.
    Rob

  • Display as Text based on LOV - formating

    I have a slight problem with
    Display as Text based on LOV report column formating.
    Whatever I try to enter, regardless where CSS Clas, CSS Style - formating simply
    doesn't work. The only formating that works is:
    Number / Date Format.
    Is there a solution for this?
    Thanks,
    Denes Kubicek

    I found a simple workarround and I will post it:
    1. Instead of using LOV I created a function that does the same
    ( using a cursor and returning a value )
    2. Since the field needed to act as a link, I used css to format the output
    and it worked just fine.
    Thanks,
    Denes Kubicek

  • Display as text (based on LOV) not working

    hi --
    I've not used this kind of item before, so there's probably some really simple thing I'm missing....
    Have the LOV:
    select objecttype_name display_value, objecttype_id return_value
    from hdb_objecttype_syn order by 1
    Return value is going into page item :P3_objecttype_id (a popup LOV). Have another item, :P3_objecttype_name, which is a display as text (based on LOV) item. When/how is this item supposed to get populated? When I select a value from the LOV, I'd expect the text item to be set to the display value of the LOV, but it is always []. The source type of :P3_objecttype_name is Sql Query, and the query is:
    select objecttype_name from hdb_objecttype
    where objecttype_id = :P3_objecttype_id
    Does the page have to be submitted before the display item is populated? Seems like that wouldn't be very helpful...
    Thanks,
    C

    HI Varad -- I'm afraid I'm new enough to all this to not know how to implement either of your solutions... and that's after scanning the forum for additional info.
    How do I get the page to submit? Is there any way to do this w/o forcing the user to explicitly press a button? (which would be way too much, as there are probably 10 LOVs on this page).
    If I choose to use javascript, 1) on what item and under what attribute do I put the script (is it on the objecttype_name that needs to be populated?), and 2) where can I find an example of what this might look like? I'm not familiar w/ it at all.
    My goal is ultimately to have an LOV that displays both the key value and the name (which I guess can be accomplished by concatenating those together in the LOV select statement), to return the name to the page, and then have the ID automatically filled in to match the key (the example I sent you is backwards, simply because I started building this page w/ only key values displayed, added the name as a test later.) And, I also want the user to be able to type in the ID (no LOV would be attached to it), and have the name automatically populated. I'm guess this could be accomplished in a way similar to having the name filled in after the value is chosen from the LOV... If I can just figure out how to do that!
    Thanks,
    Carol

  • Cascade LOV display as text (based on LOV) in clasic report

    Hi Experts,
    It is possible to use cascade LOV - item is displayed as text (based on LOV) in clasic report ? (Display AS)
    I would like to reference to another column displayed in the report in LOV.
    Example:
    select description d,
           val_strg2 r
      from domain_cntr
    where cntr_name = 'CH_PRIM_ST_NOTE'
       and val_strg1   = #PRIM_STATUS#
       and active_idc  = 'Y'#PRIM_STATUS# is the column i would like to reference.
    Is it possible ? IN CLASIC REPORT
    regards
    J :D

    Hi,
    >
    Is it possible ? IN CLASIC REPORT
    >
    Yes.
    It may a rather long thing to code, so be ready for it.
    Here is how:
    a. Use APEX_ITEM API in your Report Query. Make sure you specify the p_item_id parameter , using #ROWNUM#
    b. In the Parent LoV wrtie an onChange event trigger that fires a JavaScript function and pass the ID of the element .
    c. In this JavaScript function make an AJAX call to get the <select>...<option...>...</select> , in short the complete HTML of the child LoV
    d. Push this HTML fragment into the Child Lov. You construct the ID of the target based on the ID of parent . E.g. f01_0001 to f02_0001.
    e. You may additional keep the child invisible or disabled initially, and then make it visible/enable it after it is populated.
    Regards,

  • Cannot see Display as Text (based on lov, saves state)

    I have raised this question on the HTMLDB forum (Where is "Display as Text (based on LOV, saves state)" but in case its XE specific I am posting here too.
    I have a tabular form in the XE version of HTMLDB, and wish to use the "Display as Text (based on LOV, saves state)" option. However, this option does is not available to me - are there some conditions necessary for this option to be displayed?
    Thanks, Rob

    Rob,
    I doubt it's an XE specific issue. I've asked for more information in the original thread.
    Sergio

  • Problem with a Display Only field based on a dynamic LOV

    I have a field/item which is based on a dynamic LOV:
    select DESCRIPTION display_value, STATUSID return_value
    from CTCXFRREQS_STATUS_LOV
    order by 1
    ...and I need it to be display-only on the page. However, if I make it a display-only field, the return value is displayed, not the display value. If I change it to be a select list field, the display value is shown, as I expect and need.
    The field was based on a static LOV before, and it worked perfectly then.
    Has anyone seen this before, and have any suggestions on how to work around it?

    Hi,
    In edit item
    Display As: Display Only
    Save Session State: Yes
    Based On: Display Value of List of Values
    Named LOV: YOUR_LOV
    Regards,
    Kartik Patel
    http://patelkartik.blogspot.com/
    http://apex.oracle.com/pls/apex/f?p=9904351712:1

  • Display text fields based on value

    I have a form that has 7 text fields that are to be filled out. I have an ajax process that auto-populates those 7 fields with values based off of the return value of a pop-up dynamic LOV. Is there any way that I can hide the last 5 fields based on a certain value of one of the text fields?
    For example, my fields are:
    P1_Badge (LOV query)
    P1_First_Name
    P1_Last_Name
    P1_Title
    P1_Phone
    P1_Room_No
    P1_Email
    P1_Fax
    The LOV returns a Badge number and populates the rest of the values. But if the Last_Name = 'Smith' then I only want to display Badge, First_Name, and Last_Name and I want to hide the rest of the fields or make them disabled for editing.
    Is this possible without any kind of page submit?
    Thanks,
    Dirk

    Hello,
    Take a look at this page http://apex.oracle.com/pls/otn/f?p=11933:39 it has examples of what you want.
    Regards,
    Carl
    blog : http://carlback.blogspot.com/
    apex examples : http://apex.oracle.com/pls/otn/f?p=11933:5

  • To get the value in a field based on lov selection of another field.......

    Hi all,
    I have a requirement where
    i need to select a LOV value
    and based on that value the field next to it should be generated......
    in brief suppose i have a field name EMPLOYEE NO as lov........
    as i select the employee number the field next to it assume EMPLOYEE NAME should be retrieved based on the employee number selected..
    hope i am clear
    waiting for ur responce.....
    DEV......

    Hi,
    Assuming you are having two fields on the page. One LOV for empID (ID: empIDV) and messageTextInput for emp Name (ID: empNameV)
    1) Create a VO for your LOV having a query like SELECT emp_num, emp_name FROM employees;
    2) Create region for LOV using table using wizard based on the VO created above (choose emp_num as messageStyledText and emp_name as formValue). Also make search allowed true for emp_num.
    3) Create a LOV map1:
    LOV region item: empId
    Return item: empIDV
    Criteria item: empIDV
    4) Create lovMap2:
    LOV region item: empName
    Return item: empNameV
    Also try to implement dependent LOVs : http://sushantsharmaa.blogspot.in/2012/12/10-dependent-lov-in-oaf.html
    --Sushant                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Required Fields based on field value

    I am using Acrobat 9.1 Std. This is what I am trying to accomplish I have four text fields that I want to make required based on the selection of a radio button group.
    I have two radio buttons on the form w/ the same name w/ the button value set to Yes for one and No for another. If the radio button w/ value Yes is selected I want to set the four text fields to required. If the radio button value is No the text fields should be optional.
    Ive found similar postings for what I am trying to accomplish; however, I havent had any success in getting it to function correctly.

    Some more information on what I have tried..For simplicity Im just trying to get one text field to work, then I can repeat the java code for the other text fields.
    In acrobat Standard 9.1 I go to Forms Add or Edit Fields from there I select the radio button group (contains two radio buttons) on the left column and select properties. Then on the radio button properties dialog box I select the Actions tab. Set the Trigger for Mouse Up and the Action for Run a JavaScript . I click the Add button and enter the following into the JavaScript editor:
    if (this.rawValue == "Yes") {
    TextField1.validate.nullTest = "error";
    xfa.layout.relayout();
    else {
    TextField1.validate.nullTest = "disabled";
    xfa.layout.relayout();
    I then close the JavaScript editor, save the form and re-open to test it. I select the radio button w/ value Yes and click the Submit button and the form goes on to submit. At this point I would expect it to error because I didnt fill in any value for TextField1.
    I also tried altering the field tag with the below java:
    if (this.rawValue == "Yes") {
    TextField1.mandatory = "error";
    xfa.layout.relayout();
    else {
    TextField1.mandatory = "disabled";
    xfa.layout.relayout();
    This also didnt work. Im not sure if I am using the correct tag or not or why I am unable to get the text field to become required for submission.
    Any help would be greatly appreciated.
    Thanks,

  • Display af:outputLabel based on lov selection

    hi i have a situation where i have lov which got two option GOVT,PRIV when the lov selection is GOVT,i what to display Responsible person(s)” in
    af:outputLabel and when lov selection is PRIV i what to display Ownership in af:outputLabel am in jdeveloper 11.1.1.6.0

    yes i figure it out
    <af:selectOneChoice value="#{bindings.Organisationtypecode.inputValue}"
                                            label="#{bindings.Organisationtypecode.label}"
                                            shortDesc="#{bindings.Organisationtypecode.hints.tooltip}"
                                            id="soc1" simple="true"
                                            autoSubmit="true" required="true"
                                            valueChangeListener="#{pageFlowScope.orgDetailsBean.valueChangedorgtype}"
                                            contentStyle="width:145px;">
                          <f:selectItems value="#{bindings.Organisationtypecode.items}"
                                         id="si1"/>
                        </af:selectOneChoice>
    <af:outputLabel value="Responsible person(s)" id="ol19"
                                        inlineStyle="color:Black; font-weight:bolder;"
                                        partialTriggers="soc1"
                                        visible="#{bindings.Organisationtypecode.inputValue eq '1'}"/>
    <af:outputLabel value="Ownership" id="ol20"
                                        inlineStyle="color:Black; font-weight:bold;"
                                        partialTriggers="soc1"
                                        visible="#{bindings.Organisationtypecode.inputValue eq '2'}"/>

  • Displaying a field based on the page number

    I need to be able to print a field on the last page of a group. Is there any way to do this? The print on last page only option does not do what I need.
    Thanks

    Andrew, that's pretty much EXACTLY what I'm attempting to do at the moment.
    If you always have the same number of pages in your report, then you could use the SRW.get_page_num and if that is the page number that you expect to be the last then return FALSE from your format trigger.
    I have spent a couple of days on the problem and have been unable to get a solution.
    If only the LAST PAGE "Print Object On" option worked properly ...
    If you do find out how to do it, I'd love to hear about it: my email address is [email protected]
    cheers
    anton
    null

Maybe you are looking for

  • Adobe PDF Printing Preferences (Version Adobe Acrobat 9)

    Is it possible to specify the output PDF filename like "abc.pdf" in Adobe PDF Settings? Thanks you for answer this dummy question.

  • Help. The audio of my footage goes really quiet when dragged into Premiere Pro timeline

    Hi there, Basically, I conducted an interview and the audio sounds loud when I play it through the top left editing window on Premiere, but when I drag it into the timeline it goes quiet. I go on audio gain and it says the peak amplitude is set to -1

  • Sorting TreeByNestingTable column

    Hi all, I have implemented my table as discussed here: https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webdynpro/tutorial on creating a tree structure in a table - 27.htm Now I'm trying to sort my table columns as de

  • Mail settings not syncing

    i have itunes set to sync 1 of my 4 mail account settings. it's ticked in itunes and when i hit "sync" it says it is syncing the mail settings. once it has finished i got to the touch and check the mail and it hasn't done anything, no mail account is

  • Why will my apps have to be deleted to change mys ettings?

    every time i try to change the settings on how i manage my music or videos on my ipad2 a message pops up saying all my apps and data will be deleted. will it really delete everything, i dont want to find out the hard way