Checking  All  mandatory Input fields .

Hi All,
I have a general checkMandatory function which is working fine wiht current InputFields on view.
Now, When I add another row of input fields on that form I want them also to be checked through checkMandatory function.
How can I perform this as I want them to be checked only at the click of button.
Can I iterate through all UI elements in  OnAction and then do something?
Please guide!
please reply soon1
Sumit

Hi,
This is my checkMandatory code:
public void checkMandatory( java.lang.String displayName, java.lang.String fieldContextID )
    //@@begin checkMandatory()
     IWDMessageManager messageMgr =wdThis.wdGetAPI().getComponent().getMessageManager();
     String attributeValue = wdContext.currentContextElement().getAttributeAsText(fieldContextID);
     IWDAttributeInfo attributeInfo =wdContext.getNodeInfo().getAttribute(fieldContextID);
          if (attributeValue != null)
     attributeValue = attributeValue.trim();
     if (attributeValue.length() == 0) {
       //String fieldLabel = this.wdContext.getNodeInfo().getAttribute(displayName).getSimpleType().getFieldLabel();
     messageMgr.reportContextAttributeMessage(wdContext.currentContextElement(),attributeInfo,
     IMessagePoInvoice.EMPTY__INPUT,
     new Object[] { displayName },
     true);
I have also  done the simple types thing. It is not working. Do I have to change any other property.
Can't  I do it by iterating through all elements and then checking for mandatory Inputfields and calling checkMandatory function for them.
please reply soon!
Sumit

Similar Messages

  • Mandatory input field in View

    Hi All,
    Mandatory input field in group
    In my web dynpro application i have marked the input field "required" and in output it shows with red asterisks...
    In my view i have 2 group elements with different fields. I am using method *check_mandatory_attr_on_view* to get mandatory fields in view, its not returning all mandatory fields in view. its just returning mandatory fields in first group.
    Has any one faced this kind of issue before? Is there anything additional to be done?
    Thanks
    Rajesh Yadla

    Depending on which NetWeaver SPS your are,
    there are some errors in this method,
    so better use the other method (CHECK_MANDATORY_ATTRIBUTES).
    This seems to work well.
    Check also SAP Notes:
    [Note 1026272 - WDA: Mandatory check on view of multiple context nodes|https://service.sap.com/sap/support/notes/1091460]
    [Note 1091460 - WDA: CHECK_MANDATORY_ATTR_ON_VIEW checks only LeadSelection|https://service.sap.com/sap/support/notes/1026272]

  • 0CFM_MARKET_VALUES: PARAM_P_AUSWT as mandatory input field

    Hi BW fans
    The datasource 0CFM_MARKET_VALUES includes one mandatory input field.
    Just for the case that there are no entries for this field in the source system, how do you prevent this error message and aborting of the extraction?
    Field PARAM_P_AUSWT(Evaluation Type (Risk Management)) is a mandatory input field; enter a value
    Message no. RSM1059
    Thanks
    BEO

    You have quotation issues. Something like this:
    onBlur="alert("test");"will blow up because the parser will match the wrong quotes. You have to either escape your quotes, or use single quotes internally.
    onBlur="alert('test');"or
    onBlur="alert(\"test\");"

  • Disable all the input field in Manage Internet Access

    I have find one error that when i use adobe reader with login from my window AD a/c, i cannot use the Adobe Reader Trust Manage because all input field are disable, it is not happen in early time, so could anybody help me to solve this, thx..

    any one could help me?

  • Input Fields of Selection Screen

    HI
    GIven the program name and the Screen #, i need to figure out all the Input fields , Data type and Length  for that program( SAP STD REPORT).
    I checked out the Element List in Se51 for the program name and screen number, I need something similar to it ..I need to pull out that data. How should i approach.
    -Ravi.

    Output checkbox, means that it is a "disabled" input field.  Output Only checkbox, means that it is more like a static text box.
    F1 Help  on  Output Only.
    <i>Pure output field
    This specification makes sense only for template fields.
    At runtime, the format of a template field can be distinguished from that of a field/text field, if it is defined as an output field, but not if it is defined as an input field.
    If the flag is set for an output template, you cannot distinguish the format of a template field from that of a text field. This allows you to insert variable components in apparently fixed texts.
    At runtime, you cannot dynamically modify the input/output attributes of output templates which have this flag set within the LOOP AT SCREEN ... ENDLOOP block in PBO modules.</i>
    Regards,
    Rich Heilman
    Message was edited by: Rich Heilman

  • SAP Data Quality Management: how to replace input fields

    Hi all,
    the input fields in the SAP DQM 4.0 Real time job Job_Realtime_DQ_SAP_Name_And_Address_Match are:
    REC_NUM
    NAME_FIRST
    NAME_LAST
    NAME1
    NAME2
    HOUSE_NUM1
    STR_SUPPL1
    STREET
    CITY1
    COUNTRY
    POST_CODE1
    REGION
    ADDR_TYPE
    MTCSTD1
    MTCSTD2
    PO_BOX
    POST_CODE2    
    THRESHOLD
    I want to replace one of the fields (i.e ADDR_TYPE) with "Account_group" column.
    The idea is replace, not create of additional fields ( as described in SAP BusinessObjects Data Quality Management (DQM): Enhancements for more fields other than address data for Duplicate Check SAP Business Objects Data Quality Management ( DQM ) Enhancements for more fields other than address data for Duplicate Check.).
    Could you please let me know if the standard  XML file sent by the RFC server contains the Account_group column.
    Any other suggestions and ideas are welcome
    Thanks in advance
    Goran

    Hi,
    the additional data tab is controlled by means of classes created in DMS.
    if your requirement is something like,
    project name
    responsible person name etc..
    for this - in CL01, you can create class, say Project XYZ
    in CT04 - you can create characteristics as project name and person name..etc for this class.
    in each characteristics you can maintain the values which will serve the requirement.
    hope this helps U..!
    Thank You,
    Manoj
    award points if useful..!

  • Input field property state required

    Hi
    Just curious to know what is the purpose of a State property for an InputField ? Normal Item & Required are the possible values.
    Regards,
    Murali.

    Hi Murali,
    I would like to explain the need for the 'STATE' property of an input field in WDA with an real-time example,
    You have requirement that you need to display a Sales Order Document based on the inputs that the user gives namely Sales Order No., Material, Material No. etc..,
    Out of the few user inputs the Sales Order No. is the madatory one with which you an display the sales order document.
    So when you are creating a screen with all those user input you can define which user input should be mandatory one. In our case it is the Sales Order Number whose state should be mandatory one.
    If you make this input as a madatory one, then the WDA takes care of during the Run-time. i.e. You will not allowed to go the next page unless you fill the mandatory input field.
    Hope it helps.
    Regards,
    Maheswaran.B

  • Digital Signature Turns Invalid while setting the Property Dynamically to an Input Field

    I have an Input box that turns mandatory only if a check box is clicked.
    The Script goes Something Like This;
    if(chkbox.rawValue === 1){
         inputField.mandatory = "error";
         inputField.mandatoryMessage = "This Field cannot be left Blank";
         inputField.presence = "visible";
    } else {
         inputField.mandatory = "disabled";
         inputField.mandatoryMessage = "";
         inputField.presence = "hidden";
    I am working with Assembler Service and the Signature field is placed in the cover page after which this form is attached.
    Any clue of why the property change Invalidates the Signature?
    Note: The stand alone form where the Check box and Input field is present doesnot have a preSign event as this form doesnot contain a Signature field unless its merged using assembler. This Script is added to the Click Event of the Checkbox.
    Cheers
    Mahesh Krishnan

    weblogic.common.resourcepool.ResourceDisabledException: Pool mds-soa is Suspended, cannot allocate resources to applications ..Check server logs to find out why mds-soa is suspended. Make sure that datasource mds-soa is up and running on SOA servrs before deploying an application.
    Regards,
    Anuj

  • Highlighting input field and  table cell column in red colour

    Hi,
           I have 4 input fields and a table in my screen. All the input fields are read only.
        I have a functionality where I have to highlight a input field with the red colour. In the sense, I have to put a thin Red border over the input field without thowing any errors or messages.
           Also, i have to highlight a particular cell in the table. i.e, i have to put Red colour border over the cell of the table for some rows only. Right now i have changed the background colour of the cell for required rows, but i need Red thin border rather than changing the entire background colour.
    Please guide me on achieving these functionalities..
    Thanks and Regards,
    -Shabir Rahim.

    Hi,
    The red thin lines border you are talking about comes from the framework during the exceptions. If this is the case then refer the following links, hope this will help you.
    [Re: Automatic message for inputfields with state=required]
    [Re: Validation of InputField]
    Well without exceptions, i dont think it will come.
    thanks & regards,
    Manoj
    Edited by: Manoj Kumar on Feb 7, 2008 12:09 PM

  • Using ms project 2007 and vba macro to list all the custom fields used in the project?

    Hi,Using ms project 2007 vba macro, I would like to be able to list all the custom fields used in the project and their corresponding field names. e.g. let us say I create a calculated duration field and name it "expected duration" and the name
    of the field I select is Duration1.
    I am trying to write a macro that will list all the used custom fields such as the result would look like:
    Duration1 ---> "expected duration"
    Text1       ---> "anything"
    Flag1        ---> "....."
    Number1  ---> "..............."
    Can anyone provide me with the solution?
    Regards,
    Chuck

    John,
    I found this module, which provides the the list of custom fields used in the project but does not provide the name given to the field. Here below is the module and hope you could help me achieve this by modifying the macro to list the renamed field.
    ' MSP Checks all Custom Task Fields
    Sub checkfields2()
    'This macro will check and report out which custom task fields are used
    'It requires Project 2002 and above as it relies on the GetField
    'and FieldNameToFieldConstant methods which were not introduced until
    '2002.
    'It does not include resource fields, however it is a simple matter to
    'do it by replacing the pjTask constant with pjResource.
    'Copyright Jack Dahlgren, Oct. 2004
    Dim mycheck As Boolean
    Dim myType, usedfields As String
    Dim t As Task
    Dim ts As Tasks
    Dim i, it As Integer
    Set ts = ActiveProject.Tasks
    usedfields = "Custom Fields used in this file" & vbCrLf
    myType = "Text"
    usedfields = usedfields & vbCrLf & "--" & UCase(myType) & "--" & vbCrLf
    For i = 1 To 30
    mycheck = False
    it = 0
    While Not mycheck And (it < ts.Count)
    it = it + 1
    If Not ts(it) Is Nothing Then
    If ts(it).GetField(FieldNameToFieldConstant(myType & i, pjtask)) <> "" Then
    usedfields = usedfields & myType & CStr(i) & vbCr
    mycheck = True
    End If
    End If
    Wend
    Next i
    myType = "Number"
    usedfields = usedfields & vbCrLf & "--" & UCase(myType) & "--" & vbCrLf
    For i = 1 To 20
    mycheck = False
    it = 0
    While Not mycheck And (it < ts.Count)
    it = it + 1
    If Not ts(it) Is Nothing Then
    If ts(it).GetField(FieldNameToFieldConstant(myType & i, pjtask)) <> 0 Then
    usedfields = usedfields & myType & CStr(i) & vbCr
    mycheck = True
    End If
    End If
    Wend
    Next i
    myType = "Duration"
    usedfields = usedfields & vbCrLf & "--" & UCase(myType) & "--" & vbCrLf
    For i = 1 To 10
    mycheck = False
    it = 0
    While Not mycheck And (it < ts.Count)
    it = it + 1
    If Not ts(it) Is Nothing Then
    If Left(ts(it).GetField(FieldNameToFieldConstant(myType & i, pjtask)), 2) <> "0 " Then
    usedfields = usedfields & myType & CStr(i) & vbCr
    mycheck = True
    End If
    End If
    Wend
    Next i
    myType = "Cost"
    usedfields = usedfields & vbCrLf & "--" & UCase(myType) & "--" & vbCrLf
    For i = 1 To 10
    mycheck = False
    it = 0
    While Not mycheck And (it < ts.Count)
    it = it + 1
    If Not ts(it) Is Nothing Then
    If ts(it).GetField(FieldNameToFieldConstant(myType & i, pjtask)) <> 0 Then
    usedfields = usedfields & myType & CStr(i) & vbCr
    mycheck = True
    End If
    End If
    Wend
    Next i
    myType = "Start"
    usedfields = usedfields & vbCrLf & "--" & UCase(myType) & "--" & vbCrLf
    For i = 1 To 10
    mycheck = False
    it = 0
    While Not mycheck And (it < ts.Count)
    it = it + 1
    If Not ts(it) Is Nothing Then
    If ts(it).GetField(FieldNameToFieldConstant(myType & i, pjtask)) <> "NA" Then
    usedfields = usedfields & myType & CStr(i) & vbCr
    mycheck = True
    End If
    End If
    Wend
    Next i
    myType = "Finish"
    usedfields = usedfields & vbCrLf & "--" & UCase(myType) & "--" & vbCrLf
    For i = 1 To 10
    mycheck = False
    it = 0
    While Not mycheck And (it < ts.Count)
    it = it + 1
    If Not ts(it) Is Nothing Then
    If ts(it).GetField(FieldNameToFieldConstant(myType & i, pjtask)) <> "NA" Then
    usedfields = usedfields & myType & CStr(i) & vbCr
    mycheck = True
    End If
    End If
    Wend
    Next i
    MsgBox usedfields
    End Sub
    This is what the module gives me. But I would like to have beside Text 1 the name that is shown as below. e.g Text1 is "Test".
    Would you mind helping me achieve this?
    Thanks in advance.
    Chuck

  • Enabling Input Fields

    Hello.
    I am creating a web dynrpo application for creating a sales order. I am using Bapi_salesorder_createfromdat1.
    All the input fields on screen are disabled when application is deployed and viewed on browser. I set the enabled property of input fields as true. But still fields are disabled.
    Can anyone tell me how to solve this??
    regards
    Vijay Kalluri

    Dear Vijay,
    Try this..
    Create a new Value Node with the Structure Binding with the model node in which your values are coming.
    Then use the CopyService to copy the values from the Model node to the newly created Value Node.
    IWDNode ValueNode = wdContext.nodeYourValueNode();
    IWDNode ModelNode = wdContext.nodeYourModelNode();
    WDCopyService.copyElements(ModelNode,ValueNode);
    Now bind the Value node to your input field.
    Hope this helps!!
    Warm Regards
    Upendra Agrawal

  • Have a checkboxand input field. Diable i/p field on selection of checkbox

    Hi experts ,
    Could someone please correct me on this :-
    PARAMETERS:
        p_wbsele TYPE C AS CHECKBOX MODIF ID '123'.  
      SELECT-OPTIONS:
        s_bukrs FOR CSKS-BUKRS NO INTERVALS.
    Now if the checkbox is not checked then the input field s_bukrs should be disabled and if checked the input fieldshould be enabled.
    Follwoing code was mentioned at
    Initialization
    loop at screen.
    if screen-name = 'p_wbsele'.
    screen-invisible = 1.
    modify screen.
    endif.
    endloop.
    At selection-screen output.
    Loop at screen.
    if p_wbsele = 'X'.
      screen-invisible = 1.
      modify screen.
      endif.
    endloop.
    But the input field is not greyed out.
    Thnx
    Kylie
    Moderator message: this has been solved many times, please search before asking.
    locked by: Thomas Zloch on Sep 9, 2010 5:05 PM

    for suppose u wnt to display materail text next to material.
    now in PAI ,
    select single * from makt
    into makt where matnr = screen-matnr.
    ok now in PBO.
    if not screen-matnr is initial.
    textfield = makt-maktx.
    endif.
    Regards
    - Gopi

  • New release Safari 7.1 blocks all keyboard input in Flash Application

    Since I have upgraded to Safari 7.1, none of our Flash Web Application are accessible; Meaning that all Flash Input field are blocked.
    We have created many (R.I.A = Rich Internet Application) with Flash / Flex... And the new release of the Web Browser Safari 7.1 cannot be used to
    run the Flash application.
    Can Apple fix to quicly ?
    I believe I'm not the only one concern by this big issue; Flash platform is widely used over the world thus I want to believe that Apple is taking into account that big issue and will sort that out very quickly !
    Thank you
    Cheers

    Hi,
    I have the same issue, but only with Flash Player debug version (version 14.0.0.145 and also 15.0.0.152).
    When installing the non-debug player, I am able to input text into textfields.
    I also hope this will be fixed soon.

  • Making the input fields readonly

    hi
       iam  calling  a RFC  and it is a Custom  and not
    a pre-defined 
           and  now i need to show some data  of the  table 
         in the pop-up window   in the input fields  and all this
            fields should be readonly .  there are about  30 
           input fields and it difficult to make each and every input
    field  as readonly  ,  is there any alternative  that allows
      me too make the all the input fields readonly.

    Hi, Kishore,
    Even I tried the same but not successful. Because your container will not have Readonly propert so only way is to do it is doing for each and every element. for this also two ways are there.
    1. directly set the readonly property of each and every element in Layout tab or
    2. create a context variable of type boolean and map it to the readonly property of the UI.
    Regards,
    Srinivas.

  • Input Field Disabled in WEB UI

    Hi,
    I am new to CRM WEB UI.
    I have created Z Component and in that I have created controller and Views and model.
    I have also added all the views and models to Runtime repository.
    Created buttons for navigation which are working fine...
    I have added some fields in view via view Configuration but all the input fields are coming as disabled when I test the application.

    Hi ,
    Thanks,  S Reddy for this Post , My issue had solved.
    Thanks & Regard.
    Pappu Kumar Mehta.

Maybe you are looking for

  • Help in abap objects

    hallow i wont example in regular abap like select stetmet and how i do that in abap objects (the same code)and which benefit i have in using objects. Regards

  • Why is ISDN so much down lately?

    Hi, I encounter lately difficulties accessing SDN. Last week I got stuff like Internal Server Error 500! java.lang.NullPointerException when simply posting a forum message. Yesterday and this morning I got messages that it was down for approx an hour

  • Problem with dsc shared shared variables and error 1950679023

    I'm having trouble using shared variables on my laptop PC (with Windows XP) using Labview 8.2 and DSC.   I've set up a simple project with one VI and one shared variable library.  In the VI, I have  a while loop that writes a number from a front pane

  • Boot Camp on new Mac Pro (Late 2013)

    I am stuck with a Boot Camp installation on a new Mac Pro. I have tried Windows 8.1 Pro, Windows 8.1 Enterprise, and Windows Server 2012 R2. (Can't try Windows 7, obviously.) All three give me this at the end of setup: Windows could not update the co

  • Error in po raising

    While raising purchase order in SAP as I am getting error :"Vendor`s/manufacturer`s QM system only valid to 30.06.2010" can anyone suggest the solution