Formatting A Percentage Field

I am trying to format a text field to produce a percentage. Currently when I input 50 into the field, it produces 50.00% (rather than 50%).  I am using a javascript that another member recommended, but I would like to know how I can remove the 2 decimal places. 
I am currently using the following document-level JavaScript:
function percentKeystroke() {
    AFNumber_Keystroke(2, 0, 0, 0, "", false);
function percentFormat() {
    event.value = util.printf("%.2f%", event.value);
Along with the following for the custom format and keystroke scripts for the field:
// Custom Format script
percentFormat();
// Custom Keystroke script
percentKeystroke();
Thanks in advance for your help!

I am trying to use the above script to format a field so the end result will be the percent value and the percent symbol. The user needs to be able to enter values of 0%-100%.
If I use the percent option it requires the user enter the value as a decimal other wise 50% enters as 5000% and trying to explain this to my client is useless.
For now the field has no format. so it takes numbers and letters.
I tried the script above but it leaves the field with no formatting, is allowing  letters,  and the user still needs to enter the %.
Any sugguestions.
Thanks

Similar Messages

  • Format of Date field is loading wrongly in the Infocube 0pp_c01.

    Hi,
    Format of Date field is loading wrongly in the Infocube 0pp_c01. But it is loading properly into PSA.
    I am loading data into PP infocubes from the following DataSources.(they all are 3.x datasources)
    1. 2LIS_04_P_MATNR
    2. 2LIS_04_P_ARBPL
    3. 2LIS_04_P_COMP
    The data is coming properly upto PSA.  For example Actual Start date is loaded in cube like 733.884.
    And, it is the same issue with all the cubes. So I checked the update rules. But, in it the mapping is done properly.
    Thanks $ Regards
    Shyne Sasimohanan
    +91-9632674245

    Hi,
    HEre also value is loaded correctly. The reason u are seeing it in this format is because it is mapped into a key figure in the info cube.
    It will store the value as number of days from a standard date like 1/1/1000 or 1/1/1900 - not sure which one of these, u should be able to search and find the correct date in the forums..but this is the logic behind it
    Hope it helps.
    Regards,
    Rathy

  • How to format a numeric field in ES2 ?

    Hi...
    I'm trying to format a numeric field in LiveCycle designer using six digit and allowing zero's "000000"…
    I went to patterns for setting the format, unfortunately I couldn't know how figure it out?
    I’ve tried this pattern: null{}|zero{000000}|num.integer{}
    It didn’t work!
    what actually I’m looking for is six digit at all time for instance if enter value of 1 in the field expect to appear 000001 ,and if i enter value 567 the appearance will be 000567 in the field and so on...etc.
    Another issue is how to validate a range of numeric value like 000001-999999 so that the input will be only restricted by those values…
    Hope this is clear! And sorry for my bad English
    Best Regards...

    Hi,
    could you please share your solution?
    I have a similar problem. I need to allow zeros before my integers to be inputed to the form.
    thanks.
    Please see my posting here:
    http://forums.adobe.com/thread/870306?tstart=0

  • How to format large number field in XML so that it appears as is in Excel

    Hi
    I need help in formating the number field so that the number displays completely in Excel.
    Ex: 12345678889453 and this appers in Excel as 1.23457E+13
    Please let me know if you have any idea on this.
    Thanks

    Hi friends,
    Thanks to all of you that you all have replied my question and given your answers.
    Thanks to all of you specially Alpana Phapale, Wallie Chang, Poonam Thorat and Raghavendra Gadhamsetty, the answers given by you is the perfect one may be in different ways and only one can be used by me. But your answers were exactly correct.
    Thanks to Asha Lund, your answers is also correct but the result as per my report should be in figures and not in words.
    Whatever it may be but for repling thanks to you too.
    Please be always with me, I am very new to Crystal Report and just learnt by my own as my Boss ordered me to do this and I have to make about 50 reports within 15 days. I think the day will start from today.
    Well friends thanks a lot again for all your effort.

  • Trouble with calculating fields. Can't select (check) fields. Also can't figure out what's wrong with a division field (percent) that I created. Keep getting the pop up that format of the field doesn't allow blah blah blah... Help!

    Trouble with calculating fields. Can't select (check) fields. Also can't figure out what's wrong with a division field (percent) that I created. Keep getting the pop up that format of the field doesn't allow blah blah blah... Help!

    1. Use the mouse to select the field and then press the space bar.
    2. A null string is the same as zero. What is the result for division by zero?

  • Formatting a date field

    I am trying to format a date field so that it shows as 06/29/2005 instead of 06/29/2005 00:00:00. Im thinking that I need to use the Substr function to do this but cant get it to work. Here is what I have, @(Substr(REQUIRED_DATE,1,10)). Any help would be great.

    The field is set up as a text field. From what I have read in Help, $date20 is for when you want to make a field be the system date. I want to change the format of a date that is being pulled from my database. Can I use the $date20 function for this? Thanks

  • Invalid date format for 'Created' field in the getVersions web service Response.

    Hi all,
    I am trying to get all versions for selected document by calling getVersions method Versions.asmxweb service, but getting ‘Created’ date attribute value is in the format "29-05-2012 12:01"
    but I am expecting either one of the following date formats.
     1.      yyyy-MM-dd HH:mm:ss  or  yyyy-MM-ddTHH:mm:ssz
     2.      MM/dd/yyyy HH:mm a   (a means AM/PM)
     3.      MM/dd/yyyy
     4.      yyyyMMdd HH:mm:ss
    where do I need to change?
    what are all the formate will be support by SharePoint?
    please find attached response xml of getVersions call.
    <results xmlns="http://schemas.microsoft.com/sharepoint/soap/">
        <list id="{6A6F6CD1-2E9C-44CC-B1F5-56G7JB5C8778}"/>
        <versioning enabled="1"/>
        <settings url="http://hbngjfgj47s20/reg/_layouts/LstSetng.aspx?List={7S6F6CD1-2E9C-44CC-B1F5-KO9J8Y7Y6H78}"/>
        <result version="@0.3" url="http://vmesxsrv47s20/register/Shared Documents/Parent/child/my_doc" created="29-05-2012 12:01" createdRaw="2014-12-02T12:46:02Z" createdBy="my_dom\agi_sharepoint"
    createdByName="AGI_Sharepoint" size="288" comments=""/>
        <result version="0.1" url="http://hbngjfgj47s20/register/_vti_history/1/Shared Documents/Parent/child/my_doc" created="29-05-2012 10:01" createdRaw="2014-12-02T10:55:18Z" createdBy="my_dom\my_sharepoint"
    createdByName="my_sharepoint" size="288" comments=""/>
        <result version="0.2" url="http://hbngjfgj47s20/register/_vti_history/2/Shared Documents/Parent/child/my_doc.txt" created="29-05-2012 11:01" createdRaw="2014-12-02T10:59:25Z" createdBy="my_dom\my_sharepoint"
    createdByName="my_sharepoint" size="288" comments=""/>
    </results>
    Kindly help me on this.

    Hi,
    According to your post, my understanding is that you want to change date format for ‘Created’ field in the getVersions web service.
    Per my knowledge, you can get the date format for ‘Created’ field as “MM/dd/yyyy HH:mm a”.
    For more information, you can refer to:
    Versions.GetVersions Method (Versions)
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • When formatting a date field in a where clause the template put dot instead of comma

    Hello to Headstart Workers !
    In a query find block the template construct a where clause, in some cases, and i dont know when the template is formatting a date field putting a dot instead of a comma.
    Ex.: to_date('19-01-2001'.'DD-MM-YYYY')
    Anybody knows why or where the template do this.
    Congratulations
    Nelson

    - We created it using the HS utilities.
    - "nls_numeric_character = ,.".
    - it onky happen when the field date is not the first field in the where clause.
    - i can see the problem just after pressing find button, already in the ls_block in last_query.
    - the find_query works normally but cannot edit any line in ls_block.
    Hope that i had helping
    Regards
    Nelson
    null

  • OLE2. How to set cell format to percentage

    hi,
    how can I set the cell format to percentage? I tried with
    ole2.set_property (cell, 'NumberFormat', '%');
    OLE2.set_property(cell, 'Formula', '=A1/B1');
    but this only print a '%' at the end of the cell. Really, the cell format is not percentage, and formula is not calculated.

    solved.
    ole2.set_property (cell, 'NumberFormat', '0,00%');

  • Percentage field in Adobe forms

    Hi
    I have a requirement to display a percentage field with 2 decimal places in an Adobe form e.g. 75.00%.
    The field has been declared as type ANZHL (DEC Length=7 Decimals=2) in a data dictionary structure.
    When debugging the controlling program and the actual function module generated for the form itself the contents of the field is 75.00.
    In the layout of the form the field has been created as a Decimal field with Display pattern and Data pattern of num{zzzz9.zz%}.
    However, when the form is previewed or printed the field is displayed as 7500%.
    Does anyone have any idea how to fix this?
    Thanks

    Hello
    I know this is quite old topic, but for future reference another solution is to use '%' in the pattern.
    For example:
    you have decimal value 75.00,
         - when using pattern num{zz.99%}, it will output 7500%
         - when using pattern num{zz.99 '%'}, it will output % as a string, and the whole output will be 75.00 %
    So in second case you don't need any extra (floating or text) field to have percentage in.

  • Percentage field in infotype 0001

    while hiring a person, the percentage field in organizational plan of infotype 0001 is defaulted as 0.00, where as it should be actually 100.00.
    can any one help on what could be the possible reason and the slution.

    Hi,
    Go to PO03 then select the job /postion and then slect relattionship change mode and chenge the default percentage
    Thanks
    Paramshetty

  • Date format(for number fields)

    Hi there.
    I'm creating some sql queries wich will be executed by some users throught the Oracle client PL/SQL, and I need to format some fields in date format.
    Those fields are NUMBER(8) and they are in that format: "YYYYMMDD"
    The format I want to put that information is: "DD.MM.YYYY".
    What's the easiest way to do that?
    The version that I'm using is Oracle 9.2.0.4.0.
    Thanks by the way.

    Hi,
    Use TO_CHAR to convert the number to a string,
    use TO_DATE to convert the string to a date, then
    use TO_CHAR to format the date.
    TO_CHAR ( TO_DATE ( TO_CHAR ( numeric_column
                                , 'fm00000000'
                      , 'YYYYMMDD'
            , 'DD.MM.YYYY'
            )This shows why storing dates in some other kind of column is a bad idea.

  • Reports 6: Character format within the field

    Is it possible to apply different types of formatting (bold,italic,font size changes and font type changes) to a text within same field using Oracle Reports 6i? We are generating PDF files using Oracle Reports (legal documents) that must have proper formatting within the field and can't find way of doing it dynamically. Text for the field is pulled from the database - it is not hard-coded in report.
    Is this available in Ver 9/10?
    Thanks,
    Dejan Bogojevic

    Hi Dejan,
    You can get the desired output in HTML format in 9i/10g. Look at the "Contains HTML Tags" property in Builder Online Help. However, for PDF output this is not currently supported.
    Navneet.

  • No message for validation error "format", type "date", field "date-expired"

    Dear
    Guys,
    i am getting the following error : ((No message for validation error "format", type "date", field "date-expired"))
    When trying to upload adobe connect 7 license to the adobe connect 7 configuration wizard. the problem occurs because my server was install on Arabic Saudi Arabia date format while installation, but if i change the windows date format to US then the problem still occurs, and formatting windows is not possible, could anybody help??
    Regards

    Thank you for replying,
    No i am not on host mode, a have installed it deferent times ago successfully, but the only problem now is that during the installation windows server 2008 the default language, time and date. Was set Arabic Saudi Arabia. And even changing it does not solve the problem, as i mentioned above.

  • OBIEE Presentation Services : Default formatting for numeric fields

    Hello all.
    I need help in setting default formatting for numeric fields in criteria. If a user adds an numeric field, it does not have any formatting associated with it. I want to know how do you set default formatting (for example if user adds sales measure it should appear in default format like $1,000 or even with decimal places).
    Please help.
    Thank you.

    Hi,
    1) We have so many subject areas. If we select "system wide default for this data type", is this change going to reflect in all subject areas.No should do this subject area wise.
    2) Will this effect if we migrate from dev to prod environment.Yes it will effect.
    I hope u will follow this to-
    http://forums.oracle.com/forums/ann.jspa?annID=939 :)
    Regards,
    Srikanth

Maybe you are looking for

  • How do I get my anote data back

    I lost my Awesome App with all my data from my IPhone

  • Error when starting Repository

    Hi All, We have a new PI 7.1 system and when we start the Repository we are getting "Unexpected Exception: java.lang.reflect.InvocationTargetException" This error occurs when we start java webstart. The Directory is working. Can you please help us? T

  • Change Encoding in Graphical Mapping

    Hello guys, I have an interface like File-> PI 7.1 -> Proxy The problem is that some characters are not correct at the proxy, and I have an error when the proxy is executed. I have at the sender file adapter the encoding ISO-8859-1, but the problem i

  • Reading from a text file and displaying the contents with in a frame

    Hi All, I am trying to read some data from a text file and display it on a AWT Frame. The contents of the text file are as follows: pcode1,pname1,price1,sname1, pcode2,pname2,price2,sname1, I am writing a method to read the contents from a text file

  • Iphoto/iweb sharing

    In iphoto where are the pictures, the actual images? All i see is giant library file thats 13GB. Are all my picts in that single folder? Would i just copy that library file to a new computer if i wanted to import my library. I'm about to do a clean i