Defaulting values in IT0006 - Dynamic Actions

Hi ,
Need some help again.
This is my <b>requirement</b>:
In IT0006, if some condition exists (<b>P0001-WERKS = 'Value1'</b>), then i need to default a particular value in field <b>ORT01(with value Value2</b>) ( for primary business address subtype).  This is to be done while creation of an entry in PA30.
This is what I have <b>done so far</b>:
I used dynamic actions table view, <b>V_T588Z</b>, and for It0006, i wrote the following entries.
U1    04  08   P P0001-WERKS = 'Value1'
U1    04  09   W P0001-ORT01 = 'Value2'
Is this correct? I am not getting the expected result when I do an entry in PA30. I have ensured the condition to be true.
I would really appriciate some prompt answers.
Thanks,
Vivek

Hi Sarika,
I tried the user exit. It is not giving me expected result. Here is what I did:
In include ZXPADU01, i wrote the following code:
<i>WHEN '0006'.
        p0006-ort01 = 'Value1'.</i>
This did not default the value to any thing.
But while debugging, I saw that this user exit comes before MP000600, where in, this field gets over written, and becomes blank. As, while debugging, when I mannualy over wrote the value, it stayed. 
So what do I do now?
Also, for the dynamic actions way, suppose I have a set of P statements and W statements for the same sub-type, if I then write another set of Ps and Is (what you said in one of your replies), does it become a nested If condition, or it becomes a fresh set of If conditions?
Hope I made my query clear.
Thanks,
Vivek

Similar Messages

  • How to make a default value by using dynamic actions

    Hi,
           I want to default a field nationality in infotype 0002 as a great britan, using dynamic actions but unable to go ahead. Any help regarding this really appreciate.
    Regards
    Niranjan

    Hi,
    I need some guidance around creating dynamic action with default value, Please guide me through.
    I am aware I can set default values for new infotype, but I need to set default value for same infotype, let me explain the scenario.
    Currently employee is on one pension scheme which is called NE1 and now we are moving this employee to CRESP Pension Scheme.
    When employee is in NE1, his IT0071 has got a opt in field with a flag on, when the same employee is moved from NE1 pension scheme to CRESP Pension scheme, his new IT0071 record should have the same opt in field with a flag on, I want it to set this flag automatically using dynamic action. I dont want to update this field manually, while moving from NE1 to CRESP.
    Currently the below dynamic  action is coded when employees are being moved form NE1 to CRESP, but now they will have a opt in flag which should appear automatically, What needs to be done to make this happen?
    Please let me know if I set default value for the Opt in field for the same infotype.
    . When employees are being moved from NE1 to CRESP pension scheme we currently use a dynamic action as show below:
    0071                      04      10      I        INS,0069
    0071                      04      20      W       P0069-BEGDA=P0071-BEGDA
    0071                      04      30      W       P0069-ENDDA=P0071-ENDDA
    0071                      06      1        F        DYNACT_PAE031(ZHRPROG016)
    Also if it is not possible via dynamic action could you please explain how to create it using user exit, I am not an ABAPer.
    Your help is very much appreciated.
    Kind Regards,
    SK

  • Why can't I use Get LV Class Default Value in a dynamic VI?

    I am attempting to override a VI that uses "Get LV Class Default Value" and getting an error that I don't understand.  My parent class, "ANT Message Class", has two children - "ANT Command Class" and "ANT Response Class".  The children share a lot of data and functionality, including the factory pattern that the parent class' "Load Message Class" VI implements (see image).  I would like to override this VI with a Command version and a Response version, which would simply call the Message version with their respective classes overriding the dynamic input and output terminals.  However, I am getting the error "Front Panel Terminal 'ANT Message Class Out': Run-time type not propagated from dynamic input to dynamic output."
    Not sure how to get around this one.  Any ideas?
    Thanks,
    -Jamie 
    Solved!
    Go to Solution.
    Attachments:
    Get LV Class Default Value in dynamic VI.png ‏179 KB

    The To More Specific node is dealing with compile-type inference. In this case, you are loading a default instance from disk and then attempting to cast to the base Message class. However the type you are casting to is going to a dynamic output - this gives the compiler no assurances that the input class at run-time on the dynamic input will be the same as the output type; only that it will be a type at the top of the hierarchy. Dyanmic dispatch inputs/outputs must be the same type to guarantee some form of type safety.
    You need the Preserve node there so that you can guarantee the class at both dynamic dispatch terminals will be the same type.
    However this is probably not the best mechanism for a factory method. Factory methods should ideally be static; their job is to provide an instance of the right type (e.g loaded by path as per your example) and you don't need an instance of a class to do that. The only reason I can think of to over-ride said functionailty in a dynamic dispatch method is to provide some form of custom construction for the creation of the type. If all you are creating is an instance with nothing but the default private data then there is no reason to over-ride in the child classes.
    EDIT: Another post collision. nathand is on the money with this one.

  • Setting the Default Value for a dynamic select menu

    Hi I have a php page with 2 forms on it, one feeds the other to achieve a drill down (manufacturer > model). In the second select menu I have a default static value "Select Aircraft Model", I want to set a value for the first dynamic select menu to read "Select Aircraft Manufacturer". When I add a static value to my list it tells me I alreay have a dynamic behavior on this menu and to choose a different one. I have included the code for both menus. Thank you in advance, I know this must be a stupid question, but it's got me stumped.
    Tom
    //This is the menu I want to add the default static value to//
    <td width="667"><select name="airMake" style="width: 200px;"onchange="this.form.submit();" id="airMake">
            <?php
    do {
    ?>
            <option value="<?php echo $row_rsAirManufacturer['aircraft_manufacturer']?>"<?php if (!(strcmp($row_rsAirManufacturer['aircraft_manufacturer'], ((isset($_POST["airMake"]))?$_POST["airMake"]:"")))) {echo "selected=\"selected\"";} ?>><?php echo $row_rsAirManufacturer['aircraft_manufacturer']?></option>
            <?php
    } while ($row_rsAirManufacturer = mysql_fetch_assoc($rsAirManufacturer));
      $rows = mysql_num_rows($rsAirManufacturer);
      if($rows > 0) {
          mysql_data_seek($rsAirManufacturer, 0);
          $row_rsAirManufacturer = mysql_fetch_assoc($rsAirManufacturer);
    ?>
          </select>
          </td>
      </tr>
    </table></form>
        <form action="quoteResult.php" method="post" name="quoteForm">
          <table width="100%" border="0" cellpadding="5px">
            <tr>
              <td width="260"style="color: #000; text-align: right;">Aircraft Model:</td>
              <td colspan="2"><span id="spryselect2">
    //This is the menu that works correctly//
                <select name="airModel" style="width: 200px;" id="airModel">
                  <option value="" <?php if (!(strcmp("", ((isset($_POST["airMakeField"]))?$_POST["airMakeField"]:"")))) {echo "selected=\"selected\"";} ?>></option>
                  <?php
    do { 
    ?>
                  <option value="<?php echo $row_rsAirModel['aircraft_model']?>"<?php if (!(strcmp($row_rsAirModel['aircraft_model'], ((isset($_POST["airMakeField"]))?$_POST["airMakeField"]:"")))) {echo "selected=\"selected\"";} ?>><?php echo $row_rsAirModel['aircraft_model']?>Select Aircraft Model</option>
                  <?php
    } while ($row_rsAirModel = mysql_fetch_assoc($rsAirModel));
      $rows = mysql_num_rows($rsAirModel);
      if($rows > 0) {
          mysql_data_seek($rsAirModel, 0);
          $row_rsAirModel = mysql_fetch_assoc($rsAirModel);
    ?>
                  </select>

    Change this -
    <select name="airMake" style="width: 200px;"onchange="this.form.submit();" id="airMake">
    to this -
    <select name="airMake" style="width: 200px;"onchange="this.form.submit();" id="airMake">
    <option value="-1">Select Aircraft Manufacturer</option>
    Then if the value of 'airMake' is -1 you know that no choice was made.

  • How to include a default value in Dynamic cascading prompt from 2nd Level.

    Hi,
      I use Command Object in 'Datbase Expert' to create 'Custom Tables'  and use these tables to fetch LoVs. I use Dynamic Cascading Prompts in the reports.  I have a peculiar requirement using DCP.
      There are Four Levels as in the Example:
      Continent
       Country
       State
       City
      In the Custom Table, requirement is to create an additinal row with '' that represents 'All Values selected' for that level starting from second.  and The default selection should be '' . I defined that '*' means 'All Vales Selected in the report' This si not a problem. But the problem how to show a default value in a Dynamic Cascading Prompt i.e. how we can make sure in an default value can be selected in DCP from Second Level?
    how can the examples 1,2,3 can be achieved detaisled below beacsuse we need to show a default value in Casacading Propmt
    Eg of Schedules with DCP:
    Schedule 1   
      Continent: Europe
       Country: *
       State: *
        City:  *
      Schedule2:
       Continent: Europe
       Country: England
        State: *
         City: *
    Schedule 3:
        Continent: Europe
       Country: England
        State: Greater London
         City: *
    Schedule 4:
    Continent: Europe
       Country: England
        State: Greater London
         City: City of london

    You won't be able to have a true "default" value in the various cascading levels, since there aren't default values in a dynamic cascading parameter.  That being said, I've created a sample report in Crystal Reports 2008 that has a Command-driven DCP with '*' values for the 2nd and 3rd levels of my 3-tier DCP and have accounted for them in the record selection criteria.  You can find the sample here at https://www.box.net/shared/mav5qp337j

  • Dynamic action on "Change" of Radio group value

    Hi,
    I'm using Apex 4.1 on XE 11G.
    If I create a simple dynamic action which shows/hides a field on the change of an item of type select list this works great.
    So for example if the value of the select list is 1 then show another field and otherwise hide this other field.
    If I change the type of the first field ( the select list ) to a radio group the dynamic action stops working. It looks like the value of the radio group does not get changed when I click another value in the radio group.
    I'm somehow able to bypass this by using a dynamic action which fires when the radio group is clicked and then evaluatie it's value via JS, but that's not really the ideal solution.
    Is there some basic difference in radio groups and select lists when it comes to storing values and/or dynamic actions which are based on the change event on that item ?
    Regards
    Bas
    Edited by: Bas de Klerk on 31-mei-2012 6:42

    Take a look at the Radio group item in HTML DOM using FF/Firebug or IE/DevTools, and you will see the difference.
    If you have neither of the 2 debug tools , time you get one.
    Regards,

  • How to make dynamic actions using Set Value work in all browsers?

    I’m having a cross-browser incompatibility issue with dynamic actions using Set Value.  The dynamic action works like a charm on Chrome but has no effect on either IE or Firefox.  The code in oracle.apex.com and here are the credentials:
    Workspace: DDBA
    Username: [email protected]
    Password: redtruck12
    These code is on page 3 and here are the details:
    There are two report lists (Standard and Special) and some of the reports require additional information supplied in either select lists or text boxes.
    If the user selects a Standard report requiring a select list/text box, then the dynamic action sets the value of Special Reports to NULL (and vice-versa).
    The dynamic action is to prevent a simultaneous selection of both the Standard and Special reports.  To see how it works on Chrome, do this:
    Run Page 3
    Select the ‘Report for Search Criteria’ option from the Standard Report list.  A ‘Search Criteria’ text box appears
    Select the ‘Report by Release’ option from the Special Reports list.  A select list appears and the ‘Search Criteria’ text box disappears.
    If you do the same things on IE or Firefox, the text box does not disappear. 

    Hi,
    Things are going wrong with setting the item values to NULL. If you check your session state, you'll see that in chrome your items values indeed will be set to null, but in firefox they won't.
    Also I've noticed that you don't reset the other input fields, so their values persist in the session state. Since you submit your page every time you change one of the report select lists, this might lead to unexpected behaviour. Lastly, I've noticed you use a sql exists expression to manage the display/hide of your page items. A condition of type "Value of  expression 1 = expression 2" causes less overhead as you don't need to switch to the db sql engine for every item to validate.
    I'd suggest you rethink your specs and try to create:
    - One dynamic action (since a value of standard select excludes the value of special select, and vice versa)
    - Set the values for hidden items to null, also in session state
    - Use a refresh of region as extra event in your dynamic action, instead of submitting your page for every change.
    Regards,
    Vincent
    http://vincentdeelen.blogspot.com

  • Dynamic Action, validation check, on an Item, could not use Change event

    I am learning how to use Dynamic Actions in a 3.2.x app that was upgraded to 4.0.x. I wanted to share what I learned adding client side validation with these actions. Perhaps an Apex guru could suggest an easier method to use this feature.
    I have an existing function where a user selects multiple rows in a report page, and then assigns a single status and enters justification text for the selected rows in another page, then saves changes (via submit).
    One item, justification, is required. I replaced my JavaScript validation of an empty value, e.g., P10_JUSTIFICATION.value, with a dynamic action. The Change event was a candidate for this item, with the "is not null" Condition. However, it is possible to initiate this screen to review the status, overlook the justification text and immediately select a button to save changes. No Change event has fired. The Before Page Submit event was applicable here. This Event selection in the wizard does not provide the Item for definition and then the Condition wasn't the right context though available for selection. I selected JavaScript expression for the Condition, actually entered my original JS test expression, and created one True Action. The True action displays an Alert to tell the user that required text is missing.
    Test of this DA was not completely successful. The alert appeared but the page went on to submit anyway. I found I had to add another True Action, Cancel Event, to stop the submit. The DA was then successful.
    The Apex site examples, [http://st-curriculum.oracle.com/obe/db/apex/r40/apexdynactions/apexdynactions_ll.htm] , do a great job showing use of Change and Set Value events for Items but a user may not always navigate through items. These features were promoted for developers with no to little knowledge of JavaScript to use Apex for application development. This DA required using/understanding JS anyways.
    My next step is to implement actions on a tabular form that that has required values. It is disconcerting that I have read in the forum that the column value references such as f0x and its row number are required to get it all working (as a DOM or JQuery selector). I have already found that tabular form columns can be re-ordered from v3.2.1 to 4.0.x. I was hoping I could declare dynamic actions or simpler Javascript methods that would not rely on f0x array references.
    Thanks,
    Kelly

    It is disconcerting that I have read in the forum that the column value references such as f0x and its row number are required to get it all working (as a DOM or JQuery selector).Not necessarily. One possibility is to use descendent jQuery selectors to attach the dynamic action event handler by column heading:
    td[headers="HIREDATE"] input

  • Dynamic actions and PA-PD integration a problem

    Are you aware of an update problem with MSS and PA-PD integration?  This information was made available in a presentation to us last year.  Was this issue resolved in mySAP ERP 2004?
    Dynamic actions and PA-PD integration a problem
    Dynamic actions and PA-PD integration are not
    processed on updates made from the web (but in the
    background through a batch or call transaction session)
    That’s why most standard PCRs require HR to process
    the transaction using the SAP GUI in the foreground
    This normally affects changes to infotypes 0000 &
    0001
    Then the next slide states:
    Workaround for dynamic actions
    Review dynamic actions in table T588Z (use SE16 to
    display) and document the infotypes and values that
    trigger dynamic actions
    Incorporate those infotypes into your background
    processing and web forms (if necessary)
    Workaround for PA-PD integration
    Include the integration steps for these infotypes in your
    background processing (just as in conversions)

    Hi John,
    Not sure if it is fixed.. or can be fixed.. we are still in 47  & Use custom code to account for Dynamic Actions.. the PCR processes use the function module HR_MAINTAIN_MASTERDATA to update the infotypes. This function mimics a BDC & hence cannot handle Dynamic Actions... Basically, the issue is not with MSS but it is the way Dynamic Actions work.. to quote SAP  "Dynamic actions are not correctly processed in batch input sessions since in batch input the sequence of the screens needs to be predefined correctly. To be able to process dynamic actions in batch input, the checks of the dynamic actions need to be programmed when creating the batch input session. To avoid errors when programming and running the session, the static actions  only are processed in batch input. Calls of infotypes that are triggered by dynamic actions should be realized by separate Transaction calls.
    Please take a look at OSS Note #386027 for additional info about Dynamic Actions.
    Regards,
    Suresh Datti

  • Set Cascading LOV Item using Dynamic Action

    Hi all,
    I have the following page item:
    P1_USERNAME
    P1_COMPANY  (LOV)
    P1_DIVISION (LOV)
    P1_DEPT (LOV)
    Item P1_COMPANY, P1_DIVISION, and P1_DEPT are cascading LOV on my page.
    I also have a table that contains the user and his/her company, division, and department.
    So I have a dynamic action that when P1_USERNAME is entered. The dynamic action will pull the COMPANY, DIVISION, and DEPT information from the table and populate the page item accordingly.
    I got the dynamic action working, I can confirm this by checking the Session State of the items.
    BUT I cannot get the LOVs to display the selected value from the session state. They always reset back to "- Please Select -", which is my display value when NULL.
    For example:
    I have a record like in the table:
    Username :alex
    Company : Finance Inc.
    Division : Admin
    Dept : HR
    When I entered the username into P1_USERNAME, this is what I see in the screen.
    Username :alex
    Company : - Please Select -
    Division : - Please Select -
    Dept : - Please Select -
    While the session states of the items have been set correctly as per the record in the database.
    Has anyone experienced this before?
    I think it's because the parent LOV (company), reset the child LOVs (division and dept), when the dynamic action kicks in.
    Thanks.

    I've just taken a look at your sample page and don't think this issue is actually too complicated to solve. (Actually, it was I who was mucking around in page 1, sorry for that. I was looking at it and then had to go. Picked it up again later on and just made a copy this time)
    You change the employee. The dynamic action fires, executes plsql and sets the values in the company2/division2/dept2 fields
    Company 1 is a cascading lov. Empo has changed? Company refreshes. Cascading for division and dept as well.
    You can see this happening in sequence as well when looking at the page. Select emp, it'll hang for a second. You then get the select list refresh icons.
    The sequence in which this happens is of course a bit wrong. You set the values for the items on the client side first, but then their refresh is kicked in, and so the value setting is simply lost again.
    What makes this annoying is how P1_EMPNO is a cascading lov parent of P1_COMPANY. Changing P1_EMPNO will refresh the lovs beneath it. However, you can't simply set their values after you've retrieved the user's company/division/dept, because each lov is dependent on the one above it. Eg you change the employee. The company lov is refreshed. Because the it is refreshed, the division lov will refresh. Now you can set the value of the company lov, but not that of the division one. Why is this? The lov for division requires the value of company in the session state. If you'd set the value for company after it has finished refreshing, it will already be too late for division to pick up the value set. .
    I made a copy of your page to page 5, “tom”.
    The first I did was removing the cascade from the company lov. You don’t need this. There are simply no parent lovs for this lov, as is evident from the sql for it. The companies always remain the same companies even when you select another person; it is not dependent on another item for its values.
    Then the timing issues come in play, and with them there is also the issue of the session state.
    So now companies always show. You pick a user, it runs the PLSQL block and put values in the P5_xxx2 items. P5_COMPANY can be set now, and this is in the set value of the dynamic action. By not suppressing the change event, a refresh will be triggered on its cascading lov, P5_DIVISION.
    Refreshing P5_DIVISION will only get the new lov values (constrained within the chosen company) for this item though, and not set the value. We already have the values in P5_DIVISION2 however, and thus can use the “After Refresh” dynamic action on P5_DIVISION to do this. In short: company gets set, divisions refresh to show the correct divisions, and then the selected value is set. Again, by not suppressing the change event on this item the depending lov on DEPT will be refreshed.
    Then by using another “After Refresh” dynamic action on P5_DEPT we can set the selected value once more.
    Also important is that I changed P5_DIVISION to submit P5_COMPANY when it is refreshed, and P5_DIVISION when P5_DEPT is refreshed. This makes sure that the correct set of values is retrieved and probably why you were struggling aswell. After company has changed and division has refreshed, the value on division is set. But the correct divisions are shown only because the chosen company has been set in the session state.
    The same for division - dept. After the refresh of division, the chosen value for division is set. This change will trigger the refresh on dept, and because dept has the division in its page items to submit list, the correct values will be retrieved.
    Take note that the “debug items” are required in this solution though. Just set them as hidden and unprotect their value. Your goal should be to reduce the amount of roundtrips to the server. Why do a plsql (ajax) call just to retrieve a session state, when the value is already on the page and all in one action? Three hidden items is just so much easier than 3 extra ajax calls, the tradeoff is plenty.
    There is one more noteworthy point, and that is the fact that dept is being retrieved twice. That makes sense because of the cascading lovs. Initially company is changed, and this will refresh division and this in turn will trigger a refresh on dept. At this point the lov for dept will be empty, because division will be empty. Because we set the value of division again after it has refreshed, this will trigger a second refresh on dept, though now the correct list of values is retrieved because division has a value set. Not that big an issue, but good to point out. If you’d have another cascading lov beneath dept, it would refresh three times.

  • Dynamic action - default values

    Hi guys,
    Anybody knows if it is possible to set a dynamic action in order to default P0001-WERKS field in the Infotype 0001?
    Thank you very much!

    So you mean to say, Action 0000 Infotype and Org Assignment 0001 infotype will have different values depending on Action Type??
    This is not at all possibleeeeee!!
    The WERKS that you enter in IT0000 stores in IT0001 but not in IT0000
    Regards
    ...Sadhu

  • Dynamic action with set value on date field

    Hi,
    I'm using APEX 4.02
    I'm trying to calculate the age based on the date of birth dynamically on a form. I'm trying to do this with a (advanced)dynamic action with set value.
    I'm able to get this kind of action working based on a number field etc, but NEVER on a date field.
    I've read all posts on this subject but so far no solution. Even if I try to simply copy the value over to another date field or typecast it to a string ( to_char function ) it does not work. So for me the problem seems to be in the source field being a date field.
    I've tried using the source value as is in a select statement :
    select :P33_GEBOORTEDATUM from dual;
    and also type casted based on the date format :
    select TO_DATE(:P33_GEBOORTEDATUM,'DD-MON-YYYY') from dual
    but still no luck.
    On the same form I don't have any issues as long as the calculation is based on number fields, but as soon as I start using dates all goes wrong.
    Any suggestions would be greatly appreciated. If you need any extra info just let me know.
    Cheers
    Bas
    b.t.w My application default date format is DD-MON-YYYY, maybe this has something to do with the issue .... ?
    Edited by: user3338841 on 3-apr-2011 7:33

    Hi,
    Create a dynamic action named "set age" with following values.
    Event: Change
    Selection Type: Item(s)
    Item(s): P1_DATE_OF_BIRTH
    Action: Set value
    Fire on page load: TRUE
    Set Type: PL/SQL Expression
    PL/SQL Expression: ROUND( (SYSDATE - :P1_DATE_OF_BIRTH)/365.24,0)
    Page items to submit: P1_DATE_OF_BIRTH
    Selection Type: Item(s)
    Item(s): P1_AGE
    Regards,
    Kartik Patel
    http://patelkartik.blogspot.com/
    http://apex.oracle.com/pls/apex/f?p=9904351712:1

  • Setting default values in a php dynamic list

    I have a drop down list that is populated by a recordset consisting of two fields, company (a text field shown in the drop down list) and company_ID (an integer key )
    The default value for the field Company should be "unknown", and the form should not submit if the sleted value is "unknown"
    The selection once made is used to insert the value into  a new record, along with many others on the full form..
    The code is complicated by the fact that it also includes some java script code from a check form behaviour, shown in orange for completeness.
    How do I change the PHP code so that it shows the default value of "unknown" in the select box when run, instead of showing the last item in the companies list?
    Should be simple enough, but I am too close to see the solution.
            <td>
    <select name="Companies_ID" size="1" class="contclass" id="Companies_ID" >
              <%
    while (!compny.EOF) {
    %>
              <option value="<%=(compny.Fields.Item("ID").Value)%>" <%=((compny.Fields.Item("ID").Value == (compny.Fields.Item("ID").unknown))?"SELECTED":"")%> <?php if (!(strcmp("<%=(compny.Fields.Item(\"ID\").Value)%>", $row_rsCompany['ID']))) {echo "selected=\"selected\"";} ?>><%=(compny.Fields.Item("company").Value)%></option>
              <%
      compny.MoveNext();
    if (compny.CursorType > 0) {
      if (!compny.BOF) compny.MoveFirst();
    } else {
      compny.Requery();
    %>
    <?php
    do { 
    ?>
              <option value="<?php echo $row_rsCompany['ID']?>"<?php if (!(strcmp($row_rsCompany['ID'], $row_rsCompany['ID']))) {echo "selected=\"selected\"";} ?>><?php echo $row_rsCompany['company']?></option>
              <?php
    } while ($row_rsCompany = mysql_fetch_assoc($rsCompany));
      $rows = mysql_num_rows($rsCompany);
      if($rows > 0) {
          mysql_data_seek($rsCompany, 0);
                $row_rsCompany = mysql_fetch_assoc($rsCompany);
    ?>
              </select>
              <input name="company" type="hidden" id="company" value="<?php echo $row_rsCompany['company']; ?>" /></td>
            <td>Select from list. If it does not exist, add a Company. </td>
          mysql_data_seek($rsTypes, 0);
                $row_rsTypes = mysql_fetch_assoc($rsTypes);
    ?>
              </select>
              <input name="company" type="hidden" id="company" value="<?php echo $row_rsCompany['company']; ?>" />

    Thanks Bregent - your comment made me think again, and now the problem does not exist - in fact it never really did.
    I did not explain it properly.
    The form that I am using has many different items on it, some of which are static and some that are not.
    All the static fields show the word "unknown" when the page loads.
    None of the dynamic fields do, but I would like them to.
    Here is a section of newly created code as a test. I first created a drop down list with a default of "unknown" and then dynamically populated it. This produced the following code:
    <form action="" method="get">
    <select name="testing" size="1">
      <option value="unknown" <?php if (!(strcmp("unknown", $row_Recordset1['ID']))) {echo "selected=\"selected\"";} ?>>unknown</option>
      <?php
    do { 
    ?>
      <option value="<?php echo $row_Recordset1['ID']?>"<?php if (!(strcmp($row_Recordset1['ID'], $row_Recordset1['ID']))) {echo "selected=\"selected\"";} ?>><?php echo $row_Recordset1['type']?></option>
      <?php
    } while ($row_Recordset1 = mysql_fetch_assoc($Recordset1));
      $rows = mysql_num_rows($Recordset1);
      if($rows > 0) {
          mysql_data_seek($Recordset1, 0);
          $row_Recordset1 = mysql_fetch_assoc($Recordset1);
    ?>
    </select>
    </form>
    When I am in split view, all I see is a box with "unknown" in it, which is what I want.
    When I switch to live view, or view it in a browser, It shows the word "Z Smith & Co" - which is the last record on file in the current sort order.
    What I was trying to attain, was to put the static text "unknown" in this field, so that if the user does not select anything then the word "unknown" goes into the record of the (different) table that is being created.
    However, on reflection, I must allow the user to select whatever he likes into this field. If he does not know the company that should be there, he selects unknown from the list.
    Just shows how thinking wrongly can cause lots of problems.
    Have a merry Christmas and a Prosperous New Year.

  • DYnamic Action to set the value of a wage type in IT0014

    Dear Experts,
    i have created a dynamic action to create a record in IT0014 (wage type 92011) if another record in IT0014 (wage type 9207) is created/changed. that is:
    0014  9207  06   I        INS,0014,9211,,(P0014-BEGDA),(P0014-ENDDA)/D
    0014  9207  06   W     Q0014-BETRG=2
    now, when i change/create the wage type 9207 in IT0014, the dynamic action opens IT0014 with subtype 9211, and with begin & end dates as set in the action , but an error message that asks me to Enter Amount !!!
    why can't the dynamic action read the amount (2) which I want to insert ?!!
    Thanks in advance

    Dear Rovan,
    you should not use Q there,
    Do not set defaults for Q fields of an Infotype because the values for these fields are derived from the corresponding P fields.
    0014 9207 06 I INS,0014,9211,,(P0014-BEGDA),(P0014-ENDDA)/D
    0014 9207 06 W P0014-BETRG=2
    Regards,
    mohammed
    Edited by: 0mohammed1 on Oct 27, 2011 5:53 PM

  • Default values OM infotypes (actions)

    Hi Experts,
    anybody knows how to set default values in OM infotype when running OM actions?
    I do this in PA component through dynamic actions, but they're not applicable in OM.
    Thank you very much!

    Hi Ema,
    I think you can use a exit or badi which will trigger a workflow on saving a record. In this you have to also take into cosideration the functionality of locking record.
    Once the approval is obtained then only, your logic should actully create the valid positions.
    Thanks!
    Regards,
    Chetan

Maybe you are looking for

  • Error during Content conversion

    Hi, The scenario is file to file. Inbound and async. The encrypted data is coming from third party. we are decrypting it and doing the content conversion. Earlier there was only 1 node. now the requirement is that they will be sending the header also

  • Palm Pre showing "No Service" and losing Ev/Service over 50% of the time + random shut offs when shut.

    For starters, I have had 5 Palm Pre's.  The first pre had a battery that I was told was too small (which explained the occasional random shutdowns when being shut).  The second pre I had did the exact same thing brand new out of the box.  The third p

  • Me22n/me23n Print preview reg

    Hi, In ECC6.0 ME22N/ME23N Print preview is not working.Is it working for anyone .

  • Grant privileges for future object?

    Hi all. Need help. 1) Bob grants object priveleges on cars to Anna 2) Anna renames cars to cars_old 3) Anna creates cars . 4) Bob has no privelges to cars:( How to grant privelges on 'created in future' tables?

  • Application Note 1420750 - How to solve?

    Hello all! I need to to applicate the note 1420750 manually, not installing the support package transaction SAPK-60405INEAAPPL because it would cause another problem with existent developments. Could any one help me with some clue? The EA-APPL is Rel