Validations in Adobe Form

hello all,
        i am writing some validations in adobe form .I am not very comfortable with adobe forms but i have to work on.
validation 1:  field 'NAME' ( type is free text )should support 'several entries'.
validation 2:  field 'NAME' ( type is lookup)  and validation is ' LOOKUP vs SAP XX TRADER (another field).
validation 3: field 'PHONE' (type is numeric) and validation is 'DEFAULT BASED ON VALUE IN TRADER LOOKUP'
if any one have sample code please share..
Thank you in advance,
Prakash .S

Hi Prakash,
Please download the following PDF file and go through the File, it shows the Difference between Formula Calculations and Java Script Calculations with some of the Examples and the functions which we should use in the Formula Calculations and in Java Script.
Hope this will help you.
http://www.adobe.com/devnet/livecycle/articles/lc_designer_scripting_basics/lc_designer_scripting_basics.pdf
Thanks & Regards,
Adi.

Similar Messages

  • Date validations in adobe form

    Hi
    i have two textfields in adobe form with labels TODATE AND FROMDATE,where TODATE should always be greater than FROMDATE.can you please tell me where to write validations for adobe form and what is the code required for it.
    Thanks
    krishna

    Hi,
    Write this code inside submit button.
    As Date class is implementing Comparable interface u can use "compareTo(Object)" method which returns integer value
    Try this code.
    Date from=get the From Date(from the attribute)
    Date to=get the TO Date (from the attribute)
    int i= from.compareTO(to);
    if(i>0)
    to date is bigger
    else if(i<0)
    from date is bigger
    else
    both r same.
    Regards,
    Sunaina Reddy T

  • From and To date Validations in Adobe form

    Hi All,
    I'm new to the Adobe forms, I have a requirement to do validations on Date fields.
    from >= current
    to >= from               and use Month YYYY format (e.g., September 2009)
    Could anyone please let me know the code to validate in the Adobe form.
    Thanks,
    Archana.

    Adobe has an online reference with examples.. you can find it [here.|http://livedocs.adobe.com/livecycle/8.2/acrobat_designer/wwhelp/wwhimpl/common/html/wwhelp.htm?context=Adobe_LiveCycle_Designer_Help&file=001211.html] It gives scripting examples in both Formcalc and javascript.
    Keep it as a favorite in your browser - you'll be using it alot.

  • Validation of Adobe Form from Web Dynpro

    Hi, can you please support me with the following problem:
    I created an Adobe Form, which contains several mandatory fields. The Submit-button of the form is positioned in the WebDynpro-View, in which the Adobe Form is embedded, but not within the Adobe Form. I choce this way in order to avoid a useless submit button in the Adobe Form for the Offline Scenario.
    (How) is it possible to do a validation check in the Adobe Form if all mandatory fields are filled by clicking the Submit button outside the Form?
    Thanks in advance,
    Thorsten

    Hi Thorsten,
    That would be done exactly the same as checking mandatory text fields in a standard Web Dynpro application, the fact that you use an interactive form makes no difference. Whether you click on a submit button in the form or a button in the Web Dynpro, the end result is simply that the entered data is transferred to the Web Dynpro context and an action is triggered. In the action (Web Dynpro code) you can check if the data in the context is valid, e.g. mandatory fields or whatever validation you like. However, if you want to do validation in the form itself, so mandatory fields are also checked offline, you have to use scripting in the form itself.
    Kind regards,
    Sigiswald

  • Validation on Adobe Form

    Hi Expert...
    I have to create a offline interactive form thought SFP.
    I have some problem in my form.....
    1. I have given a pattern validation in a field (PIN CODE) it is a 6 digit numeric field.
    Now I want that when a validation Error occurred this field should be clear.
    2. Form should be validate by a validate button without using web service.
    3. After validation is complete form should be Read only by pressing submit button.
    4. Dependent Drop down List within two DD in offline scenario.
    Thank you
    Shree

    You'll need to use a script to do it. Something like this should do:
    if (event.value) {
         event.rc = true;
         var v1 = +this.getField("NameOfOtherField").value;
         if (+event.value!=(v1*0.25)) {
              app.alert("The value you entered must be 25% of the value of NameOfOtherField.");
              event.rc = false;
    (This will check if the entered value is exactly 25% of the other value... If you meant something else, please clarify)

  • Use of ADOBE form with SAP workflow for R/3 4.6C

    Hi All,
    We are thinking of usage of ADOBE form feature as one of options to design workflow for creation and maintenance of “Info record” like “Material Master” creation. BTW the existing systems are EP 7.0 with the back end SAP ERP system 4.6 C
    We would like to just check the feasibility of usage of ADOBE interactive form for above scenario. Would it be possible to go ahead with the above concept or what would be pre-requisites or risks involved?
    1.     How would system identify the role to direct the Adobe form for approval in case the form is raised by multi department?
    2.     How can the data validations in ADOBE form happen with reference to SAP std. tables?
    An early reply would be appreciated.
    Rgds,

    Hi,
    If you use EP 70 you can used guided procedure for your requirement .
    Regards

  • Adobe form validation with Print button

    Hi All,
    I have an adobe form with field validation (javascript) already set up but I'm trying to add one more feature to the validation.
    Let me explain my initial validation first:  I have 18 required fields with their tooltip name having an '*' at the end.  Any fields not filled in with this tooltip marker will show up on an alert message when the print button is selected.
    There are two fields called IException and Amount that are required but an End User might have additional IExceptions and corresponding Amounts.  Therefore I have created 5 textboxes for each but only the first IException and Amount are absolutely required (and I use a '*' within their tooltip).  Now if an End User has an additional IExceptions ("IException2") and fills out this field, I need to make it mandatory that "Amount2" would also have to be filled in.
    Here is my code: [code]
    function validateFields()
    var flg = 0
    var n = this.numFields
    var fArr = new Array();
    for(var i = 0;i<n;i++)
    var fn = this.getNthFieldName(i);
    var f = this.getField(fn);
    var tt = f.userName
    if(tt.indexOf('*')!=-1 && f.value == f.defaultValue)
    flg++;
    fArr[fArr.length] = tt;
    if(flg>0)
    app.alert('There are '+flg+' fields that require a value\n\n'+ fArr,3)
    var IException2 = document.getElementById('IException2').value;
    var Amount2 = document.getElementById('Amount2').value;
    if ((IException2.length >0) && (Amount2.length == 0))
    app.alert('Amount is missing')
    else
    document.ExceptionForm1.print();
    validateFields();
    [/code]
    Currently when one of the require fields is NOT filled in, i receive my first alert message.  If all required fields are filled in my print button doesn't work.  Also if all required fields are filled in and IException2 is also filled in but Amount2 is not, I don't receive my second Alert message.  So my code works up to the "Var IException2 = document....." and I don't know what the issue is.
    Thank you for your help in advance. 

    One more question,  since I have 4 of these...I'm having trouble getting the button to do exactly what its suppose to based on what's filled in because i think i have my '{ }' messed up and or IF/ELSE statement is wrong...can you please take a look..
    function validateFields()
    var flg = 0
    var n = this.numFields
    var fArr = new Array();
    for(var i = 0;i<n;i++)
    var fn = this.getNthFieldName(i);
    var f = this.getField(fn);
    var tt = f.userName
    if(tt.indexOf('*')!=-1 && f.value == f.defaultValue)
    flg++;
    fArr[fArr.length] = tt;
    if(flg>0)
    app.alert('There are '+flg+' fields that require a value\n\n'+ fArr,3)
    var a = this.getField('IException2').value;
    var b= this.getField('Amount2').value;
    if ((a.length >0) && (b.length == 0))
    app.alert('Since IException 2 is filled in, Amount 2 is also required')
    var c = this.getField('IException3').value;
    var d= this.getField('Amount3').value;
    if ((c.length >0) && (d.length == 0))
    app.alert('Since IException 3 is filled in, Amount 3 is also required')
    var e = this.getField('IException4').value;
    var f= this.getField('Amount4').value;
    if ((e.length >0) && (f.length == 0))
    app.alert('Since IException 4 is filled in, Amount 4 is also required')
    var g = this.getField('IException5').value;
    var h= this.getField('Amount5').value;
    if ((g.length >0) && (h.length == 0))
    app.alert('Since IException 5 is filled in, Amount 5 is also required')
    else
    this.print();
    validateFields();

  • ISR Adobe Form Validation

    hi,
    In ISR Adobe Forms I have 2 textfields where the user can enter the telephone no and email id .I want to do validation.So I have given the validation pattern as '('999')' 999-9999 and A'@'A'.'AAA.But it is showing "Field Validate Failed"..
    What is the reason?
    Can anyone tell me the steps how to validate the fields in adobe form..
    Regards,
    Rheema Rahael.

    Hi Rheema,
    Either you can do the validation messages through the BAPI return messages fromt the BADI or through scripting by using the message box method (refer adobe life designer help). I would ssugggest to do more validations at script level or do a thorough check of the form, while pressing the review button (user command -'CHECK'.).
    Regarding the validation patterns, kindly check the help doc of designer.
    Hope these helps,
    - anto.

  • How to write database validations in Adobe flex form for web Dynpro

    Hi,
    Can any one help me
    How to write database validations in Adobe flex form for web Dynpro
    Please provide some documents if u have
    Thanks in advance
    D babu

    Hi Thomas Jung  ,
    Thanx for reply.
    I will explain my requirement
    I have vendor field in flex  if  i enter vendor no in flex I am biding this field to web dynpro context field I am getting this value in dynpro .
    With this value I am checking in my SAP database if i donu2019t  get I have to through an error in flex .
    Please tell me how to through an error to flex.

  • Data Validation in Offline Adobe Form

    Hi,
    I need to validate some data through SAP tables in offline Adobe form .Please let me know how do we acheive this.
    Ricky

    Hi Liz,
    Thanks !
    First For populating data into Adobe Form we need to create a Webservices or what else.
    Second My validation included Material Numbers,Serial Numbers etc.
    About the requirment.........I have to send a offline Adobe form to person and he/she will make entries into that form (No Connection through SAP System ).
    Then after it will revert to respective person for further edition and submitted to SAP System(SAP Connected)
    Please advise the same.
    -Ricky

  • Doubts on interactive adobe forms regarding validations

    Can we apply validation logic to an interactive Adobe form?
    Regards
    Cheenangshuk Das

    Yes you can do.
    U can do either in Interface -- Initilization part or if u r using webdynpro abap for interactive form, u can do validation in method i.e once the user enters the data and hit the button present in the screen, u can do validation in the method which u call for button i.e method which get triggered once the button is clicked.
    Thanks
    Sangeetha

  • How can i create validation Checks in Online Adobe Form

    Hi Gurus
    i am trying to create Online Adobe form.how can i do the validation checks while the user enter the values in Adobe form (For Ex: lets take personnel Number if the end user enter the personnel number it must go and  check the Data base table , if its right personnel number then processes next value or if its not right personnel number then it must show the error message).  please help me.
    Thanks in Advance
    Edited by: Reddy on Nov 24, 2011 10:08 AM

    HI Reddy,
    I think you can use either  'Submit' button or  web service for the validation. When we use the web service then it will work in offline mode also(user has to be on intranet - either via remote connectivity using VPN or office network) .
    if you are going for 'Submit'  and If you want to validate the number when the user enter value, then write the code in 'Exit' event  .
    Write the below code in the  event.
    ContainerFoundation_JS.SendMessageToContainer(event.target, "submit", "", "", "", "");
    This code will trigger the submit event in the web Dynpro component.
    Hope this will helps you.
    Regards
    Shaira.

  • Adobe forms date Validation

    In webdynpro application am using interactive forms .
    In that i have a Date field. i want the user to type only in the (DD-MMM-YYYY). it should not allow the other formats.
    if he enters any other format it should say an error message and should clear the date field

    Hi
    Place the following code in the validate method. This is formcalc code
    var num = IsoDate2Num($.rawValue) - Date()
    if ( num < 0 ) then
    $host.messageBox("Invalid Date")
    $.rawValue = ""
    else
    $host.messageBox("Do whatever")
    for more check this thread
    Re: Date Validation (MM/DD/YYYY)
    Re: Adobe Forms - Locale and date format
    thanks

  • Validating Input fields in Interactive Adobe Forms with Webdynpro ABAP

    Dear Friends,
    Am new to Interactive Adobe forms with Webdynpro Abap,
    My scenario is, I have few Input fields, i need to handle the Messages when am not entering values in any of the Input Field,
    and raise the message when i click on Save Button.
    I have tried with setting the field as Required in Form itself, but i can't set the Field as Mandatory.
    I don't know how to do, Please give some needed points, as well needed some Script/Formcalc code.
    Thanks,
    Pradeep.

    Hi Pradeep,
    You can validate the fields by using javascript/formcalc logic in onclick event of button.
    Please refer the below links
    Adobe Form -How to make an Input Field Mandatory
    Validate Intercive Adobe Form
    Hope it helps you.
    Regards,
    Rama

  • Table fields Validation in online adobe form WDABAP

    Hi,
    I have a table in Online Adobe form, and one of the field in the table is Check Box, if the check box is selected the next field(with in the same table) should be left blank else it should issue some error like leave blank.
    Can some one tell me how to to do this using javascript?
    Ravi

    Ravi,
    For eg:- Lets assume you have a table name Table1 with 2 rows (Row1 and Row2) & 3 columns.
    Row 1 has three cells --> Cell1 (which contains check box), Cell2(InputField which needs to be kep blank), Cell3( Assume its a numeric field)
    Similarly Row 2 has three cells --> Cell1 (which contains check box), Cell2(InputField which needs to be kep blank), Cell3( Assume its a numeric field)
    So the hierarchy will be
    Table1
    |--- Row1
        |-----CheckBox1
        |-----Cell2
        |-----Cell3
    |--- Row2
        |-----CheckBox2
        |-----Cell2
        |-----Cell3
    Now write following code in JavaScript in the change event of CheckBox1.
    var currVal = Table1.Row1.CheckBox1.rawValue;
    //xfa.host.messageBox("Current Val is : "+currVal);
    if(currVal == 1) // Means checkbox is selected
         xfa.host.messageBox("Please Leave Next Field blank");
           Table1.Row1.Cell2.access = "readOnly";
    else
         Table1.Row1.Cell2.access = "open";
    Similarly, you need to write code for CheckBox2 of Row2.
    Chintan

Maybe you are looking for

  • Remote JDBC Problem with Oracle BPM Studio

    Hi all, i am facing the Remote JDBC Problem with Oracle BPM Studio. When i configure a Remote JDBC Connection for SQL in BPM Studio, it prompt me an error. The SQL Connection is configured as following : External Resource: Name : MyDS Type : SQL Data

  • Template table error

    Hi Friends I'm creating workflow to pull data from SQL server to BW . I've created data flow from SQL table to template table then into BW transfer structure. When I validate the project it sayd no errors but when I execute the jon I get the followin

  • Transforming xml and DataGrids

    Hello I am reading data from a large xml file. I read it in using HTTPService and the result type is "E4X". It contains information about items in a warehouse. like this <Inventory> <warehouse name="Texas"> <chairs count="900"/> <tables count="40"/>

  • Photoshop drop error

    I've created a droplet to make three seperate images. Some of them are clipped. The clipped ones run fine, but when it get to a image with no clippling path it errors and stops the droplet. An error was encountered while executing the droplet. Check

  • HT201363 I can't remember my security question answers and it's not giving me an option to do the rescue wmail

    Please help me I cannot remember my answer to security questions and I don't see the option for a rescue email