How to use standard validator with custom component?

Hi folks!
I've implemented a custom component extending UIInput. My component worked well but now I want to use a standard validator.
How can I use it??
regards,
Steven

Validation is done by UIInput.validate() which is invoked by processValidators().
So, if you don't redefine these inherited methods they will invoke the
corresponding validators.

Similar Messages

  • How to use standard APIs for customized services

    Hello,
    I try to use IUserMappingService which has some hard coded paths to services (user mapping service). However sys admin customized the services location and it's impossible to use standard SAP libraries. For example, the standard library has a path:  "com/sapportals/portal/prt/service/usermapping", but a customized path is "com/sap/portal/pdk/srv/usermapping". When I run this iView, I am getting a message: Caused by: java.lang.NoClassDefFoundError: com/sapportals/portal/prt/service/usermapping/IUserMappingService
    Please advise.
    Thanks,
    Yan

    I guess i know what the problem is. How have you given a reference to the UM service in the portalapps.xml file ??
    I think you would have given the reference as "UserMapping". Now the PRT will look for this particular service and in the portalapps.xml of this service the ClassName would be defined as com.sapportals.portal.prt.service.UserMapping, which the PRT is not able to find.
    You can try giving the FQN in the service reference, but i doubt it will work because the PRT will still look for the above class name at the predefined location.
    Regards, Akhilesh

  • How to use Spry validation with link styled submit buttons..??

    I'm working with a theme package that comes with a bunch of button styles that work with basic links.  For example:
    <a href='page.html' class='small-button smallblue'><span>Button Label</span></a>
    I've got a basic form setup with Spry validation, but the submit button needs some styling to make it look nice with the site.  Since there are already styles ready for me to turn links into buttons I figured I'd use the same thing for my submit buttons.
    To accomplish that, I'm using the following javascript...
    <script type="text/javascript">
    function submitForm() {
        document.getElementById("form_name").submit();   
    </script>
    And then I'm updating my submit button to something like this...
    <a href='javascript: submitForm()' class='small-button smallblue'><span>Button Label</span></a>
    When I do this, the form submits as expected, but the Spry validation doesn't work.  Is there a way I can make the Spry stuff work with these types of buttons?  I know I could create separate styles for the submit buttons themselves, or I could use an image type button, but I'd really like to figure out how to get these existing styles to work for me since the theme already has so many of them done for me.
    Any information on this would be greatly appreciated.  Thanks!

    Save yourself a lot of trouble and style the normal submit button as per
    <!doctype html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>Untitled Document</title>
    <script src="SpryAssets/SpryValidationTextField.js" type="text/javascript"></script>
    <link href="SpryAssets/SpryValidationTextField.css" rel="stylesheet" type="text/css">
    <style>
    .Standout {
        font-family: Geneva, Arial, Helvetica, sans-serif;
        text-transform: uppercase;
        color: #FFFFFF;
        font-size: 16px;
        background-color: #CC0000;
        font-weight: bold;
        border-style: none;
        padding-top: 6px;
        padding-bottom: 5px;
        padding-right: 64px;
        padding-left: 64px;
        letter-spacing: 1px;
    .Standout:hover {
        background-color: #000000;
    </style>
    </head>
    <body>
    <form action="" method="get" name="myform">
      <span id="sprytextfield1">
      <label for="text1"></label>
      <input type="text" name="text1" id="text1">
      <span class="textfieldRequiredMsg">A value is required.</span></span>
      <input name="input" type="submit" class="Standout">
    </form>
    <script>
    var sprytextfield1 = new Spry.Widget.ValidationTextField("sprytextfield1", "none", {validateOn:["blur"]});
    </script>
    </body>
    </html>
    Gramps

  • How to use standard function keys as custom keys

    how to use standard function keys as custom keys.
    i have encountered that problem while developing a screen, there i'm supposed to use standard function key F2 ( which actually meant for choose) for clearing the screen fields where the cursor is present and f1 for saving data that entered in screen fields, etc...
    kindly help me out.

    Hi ,
    Solution to use SAP reserve function keys F1 .. F4 (mostly this requirement comes up for RF screens) can be acheived by assigning your new Function code using the Menu path Utilities --> F key Consistency in the Menu Painter (SE41) . Once you assign your cutom function code to the standard Fn keys the only remaining step is to make sure that you set a curson on any of the field on sceen by using the Key Word "SET CURSOR" .
    If you dont use the key word SET CURSOR in the PBO of the screen then you might not see any response for F4.
    Thanks

  • How to use the validation.xml in struts validation?

    Can any one please help me, how to use the validation.xml in struts validation? possible please give me simple example.
    Edited by: SathishkumarAyyavoo on Jan 31, 2009 12:03 PM

    These 2 are the good articles for the beginners to do validation things in Struts. you can follow any one of them.
    1. [http://viralpatel.net/blogs/2009/01/struts-validation-framework-tutorial-example-validator-struts-validation-form-validation.html]
    2. [http://www.vaannila.com/struts/struts-example/struts-custom-validation-example-1.html]
    All the best.

  • How to use standard SAP stylesheets in WAD

    Hello ,
    I created a new Web template.
    Assigned a data provider, inserted a table.
    In order to view i include a Analaysis box in one of the cell of Table.
    Now i need to change the colours of result rows.
    How to use Standard Stylesheets provided by SAP.
    Where this stylesheets will be located
    Under which properties.
    How to use those.
    How to edit those and save as we wanted.
    An y step by step documents, please send it to [email protected]
    I want to include Information button in Template, so when executing if user click this button he/she should know,
    What are provided variables and if they chosen some specific variable restriction to see the result,
    Also by default this information should get print.
    In standard sap portal, this button is located on upper right corner.
    Please advise.

    Thanks Rusty,
    Thats exactly right,
    I included a naviagtion block and it worked well
    But while printing the query on Web template, It only prints the data that is coming in Analysis block.
    Similarly while running the query thru BEX to Portal,
    Navigation block is on left, but while printing it prints exactly every data in Information tab.
    Information is the button located on upper right corner.
    If you click, it will give you information such as , which restrictions u did, which extra filters you added everything.
    And while printing it prints this information too.
    I want to do the same designing for my custom Web template.
    How can i do that.
    I already added navigation block, so it will be easy for users to drag and drop Chars and KFs in rows and columns as well as filter if they needed.
    I hope you are trying to understand.
    Also for using stylesheets can you suggest.
    So that i can make changes to row and columns.
    I am unable to locate stylesheet in any of the properties.

  • How to use *MonitorManager* to add custom messages in channel monitoring?

    Hi experts,
    How to use MonitorManager to add custom messages in channel monitoring for custom adapter development(Not in audit log).
    like
    Type   Time Stamp   Message ID   Explanation 
      6/25/11 6:39:47 AM 00199942-6e43-02df-96ca-8b538c63dd98 Message processing completed successfully
      6/25/11 6:39:47 AM 00199942-6e43-02df-96ca-8b538c63dd98 Message with ID 00199942-6e43-02df-96ca-8b538c63dd98 processed
      6/25/11 6:39:46 AM 00199942-6e43-02df-96ca-8b538c63dd98 Message processing started
      6/24/11 6:43:26 AM 00199942-6e43-02ef-96b1-7650f3495e03 Message processing completed successfully
      6/24/11 6:43:26 AM 00199942-6e43-02ef-96b1-7650f3495e03 Message with ID 00199942-6e43-02ef-96b1-7650f3495e03 processed
      6/24/11 6:43:24 AM 00199942-6e43-02ef-96b1-7650f3495e03 Message processing started
      6/23/11 6:45:52 AM 00199942-6e43-02df-9698-5be345a9ddf5 Message processing completed successfully
      6/23/11 6:45:52 AM 00199942-6e43-02df-9698-5be345a9ddf5 Message with ID 00199942-6e43-02df-9698-5be345a9ddf5 processed
      6/23/11 6:45:50 AM 00199942-6e43-02df-9698-5be345a9ddf5 Message processing started
      6/22/11 6:43:30 AM 00199942-6e43-02ef-95ff-2c03493dc078 Message processing completed successfully
    Edited by: SAP_PI_D on Jun 28, 2011 12:10 PM

    Solve by myself

  • Using Hibernate as a Custom Component

    I don’t know whether this question is appropriate in LC context.
    Our scenario, We have very complex logic in each of JDBC store/retrieve activity in the process. We would like to move this part into Hibernate based custom component.
    We tried with simple Hibernate persistence class but it seems to be LC not loading them.
    1)      Is this the restriction with LC? (using hibernate as a custom component)
    2)      What is the appropriate solution?
    You help is highly appreciated

    Jasmin,
    Is your class included in the custom component?
    Yes, It is a annotated entity class,
    When creating sessionFactory it is not loading the class.
    i'm using flowing code block for creating sessionFactory,
    factory =
    new AnnotationConfiguration().addAnnotatedClass(dao.entity.UserEntity.
    class).setProperty(
    "hibernate.dialect",m_dialect ).setProperty(
    "hibernate.connection.driver_class", m_driverClass).setProperty(
    "hibernate.connection.url", m_connectionUrl ).setProperty(
    "hibernate.connection.username",m_userName).setProperty(
    "hibernate.connection.password", m_password).setProperty(
    "hibernate.hbm2ddl.auto", m_hbmTodll ).setProperty(
    "current_session_context_class",m_contextClass ).configure(resource).buildSessionFactory();
    Is the jar referenced in the class patch section of the component.xml?
    Yes , I have tried for this approch too , but class is entity class is not loaded.

  • How to call standard report with in zprogram?

    Hi Sap experts,
    How to call standard report with in zprogram.
    For example if country is 'US' then call Zprogram(zprog_US).Inside zprogram call standard report(rhecm_change_proc_status).If country is 'CA' then call zprogram.Inside zprogram call standard report.For same othercountres like 'PR','GB','ES'.Actually HR_ECM_READ_FEATURE_CARGP will having the input as employee id and will return the CAREA(County like 'US','PR'......).Kindly help me what is the procedure?
    Regards,
    Sujan

    >
    sujan T wrote:
    > Thanks for your reply.
    >
    >    What is the logic to call the standard report from zprogram?Inside the zpogram how to call standard report?
    >
    > Regards,
    > Sujan
    no special logic is required
    If u want to use
    RPUAUDOO IN THE ZREPORT.
    Put the submit button where ever required
    ex: In zreport after certain process reacedu want to call then use
    submit rpuaudoo and return.
    Regards
    Sas

  • How to use standard Smart forms

    hi All,
    Pls give me the detail for smartform ie how to use standard smart forms and how to modify them in SAP 4.7EE
    Thanks,
    Nitin

    Hi,
    first u copy the standrad smartform to z and then modify it,
    SOME STANDARD SMARTFORMS
    SF_EXAMPLE_01,
    SF_EXAMPLE_02,
    SF_EXAMPLE_03,
    LB_BILL_INVOICE,
    ENETR SMARTFORMS TCODE
    PRESS F4 HERE U FIND ALL STANDARD SMARTFORMS
    OR
    U GO TO TRANSACTION CODE NACE
    SAMPLE PROGRAM FOR SMARTFORM,
    . Create a new smartforms
    Transaction code SMARTFORMS
    Create new smartforms call ZSMART
    2. Define looping process for internal table
              Pages and windows
          First Page -> Header Window (Cursor at First Page then click Edit -> Node -> Create)
          Here, you can specify your title and page numbering
          &SFSY-PAGE& (Page 1) of &SFSY-FORMPAGES(Z4.0)& (Total Page)
          Main windows -> TABLE -> DATA
          In the Loop section, tick Internal table and fill in
          ITAB1 (table in ABAP SMARTFORM calling function) INTO ITAB2
    3. Define table in smartforms
               Global settings :
               Form interface
               Variable name    Type assignment   Reference type
               ITAB1               TYPE                  Table Structure
               Global definitions
               Variable name    Type assignment   Reference type
               ITAB2               TYPE                  Table Structure
    4. To display the data in the form
        Make used of the Table Painter and declare the Line Type in Tabstrips Table
         e.g.  HD_GEN for printing header details,
                 IT_GEN  for printing data details.
         You have to specify the Line Type in your Text elements in the Tabstrips Output options.
          Tick the New Line and specify the Line Type for outputting the data.
          Declare your output fields in Text elements
          Tabstrips - Output Options
          For different fonts use this Style : IDWTCERTSTYLE
          For Quantity or Amout you can used this variable &GS_ITAB-AMOUNT(12.2)&
    5. Calling SMARTFORMS from your ABAP program
    REPORT ZSMARTFORM.
    Calling SMARTFORMS from your ABAP program.
    Collecting all the table data in your program, and pass once to SMARTFORMS
    SMARTFORMS
    Declare your table type in :-
    Global Settings -> Form Interface
    Global Definintions -> Global Data
    Main Window -> Table -> DATA
    Written by :  SAP Hints and Tips on Configuration and ABAP/4 Programming
                        http://sapr3.tripod.com
    TABLES: MKPF.
    DATA: FM_NAME TYPE RS38L_FNAM.
    DATA: BEGIN OF INT_MKPF OCCURS 0.
            INCLUDE STRUCTURE MKPF.
    DATA: END OF INT_MKPF.
    SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001.
    SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR.
       MOVE-CORRESPONDING MKPF TO INT_MKPF.
       APPEND INT_MKPF.
    ENDSELECT.
    At the end of your program.
    Passing data to SMARTFORMS
    call function 'SSF_FUNCTION_MODULE_NAME'
      exporting
        formname                 = 'ZSMARTFORM'
      VARIANT                  = ' '
      DIRECT_CALL              = ' '
      IMPORTING
        FM_NAME                  = FM_NAME
      EXCEPTIONS
        NO_FORM                  = 1
        NO_FUNCTION_MODULE       = 2
        OTHERS                   = 3.
    if sy-subrc <> 0.
       WRITE: / 'ERROR 1'.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    call function FM_NAME
    EXPORTING
      ARCHIVE_INDEX              =
      ARCHIVE_INDEX_TAB          =
      ARCHIVE_PARAMETERS         =
      CONTROL_PARAMETERS         =
      MAIL_APPL_OBJ              =
      MAIL_RECIPIENT             =
      MAIL_SENDER                =
      OUTPUT_OPTIONS             =
      USER_SETTINGS              = 'X'
    IMPORTING
      DOCUMENT_OUTPUT_INFO       =
      JOB_OUTPUT_INFO            =
      JOB_OUTPUT_OPTIONS         =
      TABLES
        GS_MKPF                    = INT_MKPF
      EXCEPTIONS
        FORMATTING_ERROR           = 1
        INTERNAL_ERROR             = 2
        SEND_ERROR                 = 3
        USER_CANCELED              = 4
        OTHERS                     = 5.
    if sy-subrc <> 0.
       MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    Thanks&Regards,
    Phani
    POINTS HELPFUL

  • How to use the validations and exceptions  in BPEL

    Hi,
    How to use the validations and exceptions in BPEL.
    pls provide one sample example to give the exceptions and validations in BPEL

    Hi,
    For example you can create a simple BPEL Process and you can throw an error during running process. If input data is not valid and format is not correct you can throw error using throw activity and using catch activity you can catch particular error. The catch-all will handle all the error occurred with the scope.
    you can also refer faulthandling section in the link for more information related to exception handling.
    http://download-west.oracle.com/docs/cd/B31017_01/integrate.1013/b28981/faults.htm#sthref1188
    Regards,
    Deepa

  • How to do file validation with ODI 10.1.3.5

    Hi Team,
    Please help me, how to handle file validation with ODI?
    My source is files.
    Requirement:
    With ODI i have to do the file validation and file data loading successfully. Once it is successfully done then i have to move the particular file and move to different directory.
    Any internal tool is there in ODI package to watch the file.
    Regards,
    Suresh

    Hi Suresh,
    You can do your file loading and validation in an ODI interface.
    Once you are done with the interface, add it to a package, you can set up subsequent steps in the package to move the file to another location using the built in ODI file utilities in the package.
    Terrence.

  • How to create contextual event with custom payload?

    I use the following code to invoke contextual event from my region via the "action-listener" of a command-link:
    <af:commandLink text="#{row[def.name]}" id="cl1"
    styleClass="tableLinkActive"
    actionListener="#{backingBeanScope.PanelToConveroFormManager.handleSelectedRow}">
    The following "action-listener" is designed to pass the current selected record key to the "consumer" of the contextual event:
    public void handleSelectedRow(ActionEvent actionEvent) {
    String currentRecordKey = getCurrentRecordKey();
    JUEventBinding eventBinding = (JUEventBinding)BeanUtils.getBindings().get("RefreshParentEvent");
    if (eventBinding != null) {
    ActionListener actionListener = (ActionListener)eventBinding.getListener();
    actionListener.processAction(actionEvent);
    How do I pass the "currentRecordKey" value as a custom "payload" via the event-binding "RefreshParentEvent" in the above code?
    Is there any code example on using contextual event with custom payload?

    Hi,
    the custom payload is referenced when you set up the event itself. You use EL in the custom payload definition to point to a managed bean method that when called accesses the current rowKey. The Java code you show just passes the ActionEvent of the ADF Faces command button and invokes the event. It does not manipulate the event definition.
    <eventBinding id="eventBinding"
                      Listener="javax.faces.event.ActionListener">
          <events xmlns="http://xmlns.oracle.com/adfm/contextualEvent">
            <event name="testEvent"
                   customPayLoad="#{mymanagedBean.rowKey}"/>
          </events>
        </eventBinding>Frank

  • How to use Oracle partitioning with JPA @OneToOne reference?

    Hi!
    A little bit late in the project we have realized that we need to use Oracle partitioning both for performance and admin of the data. (Partitioning by range (month) and after a year we will move the oldest month of data to an archive db)
    We have an object model with an main/root entity "Trans" with @OneToMany and @OneToOne relationships.
    How do we use Oracle partitioning on the @OneToOne relationships?
    (We'd rather not change the model as we already have millions of rows in the db.)
    On the main entity "Trans" we use: partition by range (month) on a date column.
    And on all @OneToMany we use: partition by reference (as they have a primary-foreign key relationship).
    But for the @OneToOne key for the referenced object, the key is placed in the main/source object as the example below:
    @Entity
    public class Employee {
    @Id
    @Column(name="EMP_ID")
    private long id;
    @OneToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="ADDRESS_ID")
    private Address address;
    EMPLOYEE (table)
    EMP_ID FIRSTNAME LASTNAME SALARY ADDRESS_ID
    1 Bob Way 50000 6
    2 Sarah Smith 60000 7
    ADDRESS (table)
    ADDRESS_ID STREET CITY PROVINCE COUNTRY P_CODE
    6 17 Bank St Ottawa ON Canada K2H7Z5
    7 22 Main St Toronto ON Canada     L5H2D5
    From the Oracle documentation: "Reference partitioning allows the partitioning of two tables related to one another by referential constraints. The partitioning key is resolved through an existing parent-child relationship, enforced by enabled and active primary key and foreign key constraints."
    How can we use "partition by reference" on @OneToOne relationsships or are there other solutions?
    Thanks for any advice.
    /Mats

    Crospost! How to use Oracle partitioning with JPA @OneToOne reference?

  • How to use the validation work in Both TAB and Mouse keys in Forms6i

    Hi,
    I have a validation script once it's validated it should execute the query.But using When-Validate-Item i can't use execute_query.I am able to use the validation in Key-Next-Item trigger but if the user moves the cursor using mouse then it's not working.
    How to use the validation script working in Both Scenarios(Tab and Mouse keys).
    Can anyone please give inputs to rectify the above issue?.

    So you have multiple fields, but on at least one of them if it's valid you immediately want to execute the query?
    You could create a hidden field in a control block Query_Now default 'N'. In a WHEN-VALIDATE-ITEM on your item, if it's determined to be valid, then set Query_Now to 'Y'.
    In a WHEN-NEW-ITEM-INSTANCE at block level, check if Query_Now is 'Y'. If it is then execute the query (and set it back to 'N').

Maybe you are looking for

  • I have an ipod touch and want to purchase an ipad can i use one account

    I have an Ipod touch and want to purchase an ipad.  Can the same account be used.  Can my purchases on my ipod touch be synced to my ipad?

  • How do i make groups work again?

    I had a number of email GROUPS in the last version of the OS (Mt Lion I believe) & with MAVERICKS upgrade those email groups no longer can be copied to an email. This is a DISASTER! I have several groups of over 700, I'm NOT going to individually wri

  • Sound recording in v.11.602.168

    When using IE 8.0 or FF I experience problems with sound recording in flash. This occurs since updated flash versie 11.6.602.168. The recorded sound (microphone) is played distorted. This seems to be a bug, since in earlier versions there was no prob

  • Non supported character set error

    Hello, I have a j2ee application that uses OLAP API to make queries against cubes created with cwm2 packages, in a database (db 1). I've replicated the schema in another db (db 2), importing the user (with a dmp file) and throwing the object creation

  • Transferring recieved pics to Gallery

    I want to get pics of my grandson printed from my phone, which are in Messages / Saved Items. The shop I went to said that they must be in the gallery for them to print them. The assistant didn't know how to transfer them to Gallery and neither do I.