Remove the spaces and characters not a calculated field standard

Hello

I am fairy new forms Adobe script, but I managed to do that day. I am currently working on a form that we send to the suppliers to implement in our systems.

One of the fields is called "Name of organization", which has a custom format script that modifies the text entered in uppercase in the field output:

Event.Value = event.value.toUpperCase ();

I have a hidden field "Own name branch" which is a code of calculation organistion which allows us to identify the organization within our systems (which can use letters). I need 'Own organization name' to be a calculation of "Name of organization" with all the spaces and non-standard characters deleted (", ([]) @$' &... etc").

Could someone help me with this?

Thanks in advance

Chris

This should do the trick:

Event.Value = this.getField ("Organization Name").valueAsString.replace(/[\W,_]/g,"" ");

Tags: Acrobat

Similar Questions

  • Remove the spaces and special characters to a form field

    Hello

    I am tragically new to all this, but I'm trying to create a form in Adobe Acrobat 9.  I am trying to use a custom script Format to make entries in a form field and automatically remove the spaces and special characters (hyphens specifically).  For example, if a user 'RAN - 99 06' entries I want to change it to "RAN9906."  I found this script that does not allow users to input special characters

    If (! event.willCommit) {}


    Event.change = event.change.replace (/ [------$# ~ %------*------*------^-------------(\)------+=------[\]------{\}; \ "\ <>\ \?"]) \ | \\\ !] /g, "");

    }

    And it's OK, but I can't understand how to prohibit the spaces.  In addition, the perference would be a script to allow users to enter data as they wish, but to clean after leaving the text field.

    Thanks in advance!

    Yes, there are a few changes during the passage of the code of the event in the sequence of keys to the Validate event.

    First of all, you need not try the willCommit. In fact, when the sequence of events of field reached the Validate event, the field is already committed. The Validate event does not therefore the property of willCommit.

    Secondly, in the Validate event, you work on the event.value and either event.change. Thus, you will replace accordingly.

    And who should actually do.

    I hope this can help.

    Max Wyss.

  • Remove the spaces and special characters.

    Hi all

    Here is the table of phone having a column that is 'phno' and the values are the below in this format.

    I need given the output.

    My client uses oracle 8i version.

    EmplId

    PhNO

    output

    121212

    605/339-9276

    6053399276

    222222

    251/813-0663

    8132510663

    323232

    208-585-1594

    2085851594

    232323

    352.735.8285

    3527358285

    Thank you

    music

    Hello

    DEFINITION of use,

    If it is possible to enumerate all special characters, do this way:

    SELECT emplid, phno

    REPLACE (phno

    , '9 ./'

    , '9'

    ), Exit

    FROM table_x

    ;

    If it is impossible, or if it is easier to display the characters that you want to keep, then do it like this

    SELECT emplid, phno

    REPLACE (phno

    , '9  || TRANSLATE (phno

    , ' ?' 0123456789

    . '?'

    )

    , '9'

    ), Exit

    FROM table_x

    ;

    Whatever it is, the argument 3 of TRANSLATE is one of the characters that you want to keep (any), and the 2nd argument is that same character, followed by all the characters that you want to remove.

    Nevermind, you use such an old version.  Regular expressions are much easier.

    This will leave 1 "at the beginning of '13527358285'.  How to remove characters like this depends on means exactly what "characters like this.  It can probably be done in Oracle 8 without too many problems, according to your needs.

  • Remove the spaces between the css attributes?

    Hello! I know that I can customize my preferences to 'apply the updated source shaped', but it is automatically added to spacing to the attributes of the tag and I don't see a way to change this in the options I give. I want to write my code without spacing in the attributes. Believe it or not, it is easier on my eyes in this way.

    That's what I prefer:

    whatever {width: 40%; height: 25% ;}}

    If I use source formatting, it does this:

    whatever {width: 40%; height: 25% ;}}

    If I can't change this behavior in the settings, not much, but I want to assure you that I have not just miss.

    Thank you!

    You don't miss anything.  DW uses conventional spaces between the CSS attributes.

    You can shrink your CSS code at the end of the project.  That will remove the spaces and line breaks.

    Nancy O.

  • Remove the left and right spaces with calculation

    I read in this forum that I can create a SQL expression calculation after 'Send' to remove the spaces to the left. I put in the source: ltrim(:P209_DESCRIPTION), but it did not work. You have another idea to achieve this? Thank you.

    Let us first find what you really use the following to replace all tabs with ' ~' and all the spaces with "%". This will give us a clearer picture of the characters that we have

    Select translate ('asd fd, chr (9) |) Chr (32),'~ %') of the double

    Then, we can use

    Select ltrim (: P209_DESCRIPTION, chr (9) |) Chr (32)) of the double

    for trim tabs and spaces

    Kind regards

    Vishal

    Oracle APEX 4.2 reports | Packt Publishing

    Vishal blog

    Please mark the reply as useful/correct if it solves your problem

  • Need to remove the space between &lt; af:panelGrouplayout &gt; and &lt; af:panelBox &gt;

    Hi all

    I use JDeveloper 11.1.1.6.

    My scenario is I need to stretch some fields for all browsers, so I use Panel box inside the < f: facet center = name > panelStretchLayout.

    It works very well. But some scenarios need to display the header above the group box elements. Then I try to add panelGroupLayout in < f: facet = top name >. It is stretching very well, but is always to show space between < af:panelBox >.

    How can I remove the space between < af:panelGroupLayout > and < af:panelBox >?

    My Codes like this,

    < af:panelStretchLayout id = "PSL1" inlineStyle = "" margin-top: 30px; ">"

    < f: facet = 'top' name >

    < af:panelGroupLayout id = "pgl4" layout = "vertical".

    inlineStyle = "" background-color: red; ">"

    < af:panelGroupLayout layout = "horizontal" id = "pgl1" >

    < af:outputText value = 'Day' id = "ot1" / >

    < af:outputText value = "Week" id = "ot2" / >

    < af:outputText value = 'Months' id = "ot3" / >

    < af:outputText value = 'Year' id = "ot4" / >

    < / af:panelGroupLayout >

    < / af:panelGroupLayout >

    < / f: facet >

    < f: facet name = "center" >

    < columns af:panelDashboard = rowHeight '1' = "100%" id = "pd1" >

    < af:panelBox id = "pb1" showDisclosure = "false".

    showHeader = "never" > < / af:panelBox >

    < / af:panelDashboard >

    < / f: facet >

    < / af:panelStretchLayout >


    Thank you...

    Same answer as your other thread need to hide the space between &

    Use firebug to see if a style is the cause because it is not reproduced.

    Timo

  • all of my photos in icloud were removed from the restoration (and did not find the album recently removed to icloud)



    all of my photos in icloud were removed from the restoration (and did not find the album recently removed to icloud)

    The opposite happened to me - in the opposite direction! I found all my pictures from Nokia mobile in icloud on my iPad a few days ago, had no blue cogwheels devices! The two devices + home phone is all about wireless internet of the contract with ORANGE in Europe! They will not help,

    I think my router - put in place by an expatriate for me - is hacked because of the problem. I didn't ask him to change my contract or warn of my move when I did 2 years ago - but he went ahead and made Orange disclose no information telling me his "confidential".

  • Initially, I downloaded the application and was able to access all my photos by album, photostream, fb, etc.. Now, it will not go all. After you remove the application and try to download it, it says that I have to pay for it (yet) any help would be

    Initially, I downloaded the application and was able to access all my photos by album, photostream, fb, etc.. Now, it will not go all. After you remove the application and try to download it, it says that I have to pay for it (yet) any help would be appreciated.

    Sounds like a question of verification on any market that you have bought PS Touch. Have you tried contacting Google and Apple to see what they say?

  • 5 Lightroom has stopped working. A says to remove the program and reinstalled. Installation of creative cloud does not deliver to 0%. What's wrong? With the help of a PC.

    5 Lightroom has stopped working. A says to remove the program and reinstalled. Installation of creative cloud does not deliver to 0%. What's wrong? With the help of a PC.

    I installed again the creative cloud. Now it's working.

  • How to remove the jump line, characters and past of a table column?

    HII,

    I m using 4 Apex.
    I m find the problem by removing the line break, characters and captures existing data in the column of the table.


    thnx in advance

    for example

    replace(replace(l_string_var, chr(10)),chr(13))
    

    Best regards
    Marko

    Published by: Marko Goricki, January 17, 2011 10:52

  • New HP Photosmart 7520 e-all-in-one printer from the box, removed the tape and cartridge access

    I have a new HP Photosmart 7520 e-all-in-one printer just out the box. I removed the tape and cartridge access door does not open more than 40 degrees. The figure represents about 80 degrees. I'm afraid to force it. I can't put new cartridges in the printer. Very frustrated trying to get help. It doesn't seem to be a phone number or Web site for direct assistance. HP has really gone down hill. Help!

    Hello

    Mine is about 45 degrees, sufficient space to install the ink cartridges.

    Kind regards.

  • How can I remove the footer and header view print?

    The function "file > config page" does not display the options to remove the footer and page header.

    This has happened

    Each time Firefox opened

    == I try to print

    If you want to remove the header or footer at all times (there is no user interface as in the layout under Windows or easily change) in Firefox under Linux, you can erase the preferences different values to get rid of both of them.

    Type of topic: config in the URL bar and press ENTER.
    If you see the warning, you can confirm that you want to access this page.

    Filter = header
    Each of these prefs right click and select Edit, then backspace or use delete to erase the characters - and then click OK.

    Repeat the same for the footer.

  • How to remove the spaces in the queue

    Hello

    I want to generate a spoolfile sqlplus, but trim remove the spaces to the left. What do evil?

    For example, the value in the column 4 is 9 '9 '. This is a char (1) column

    SQL > SELECT age as OF | « ; »,
    2 KONTO_LIEFERID | « ; »,
    NUMBER 3 | « ; »,
    4 TRIM (ARBEITSZIFFER) | « ; »
    5 FROM av_abst_mp_ifrs
    6. WHERE age as of = '20081230'
    7 AND number = '9851674900'
    8.
    20081230; K01; 9851674900; 9;
    20081230; K01; 9851674900; 9;
    20081230; K01; 9851674900; 9;
    20081230; K01; 9851674900; 9;
    20081230; K01; 9851674900; 9;
    20081230; K01; 9851674900; 9;
    20081230; K01; 9851674900; 9;
    20081230; K01; 9851674900; 9;

    Hello

    Spaces to the exit spaces for the columns (not spaces for column values), you concat all the values in a single column, like this...

    SQL> SELECT STICHTAG||';'||
    2 KONTO_LIEFERID||';'||
    3 KONTONUMMER||';'||
    4 TRIM(ARBEITSZIFFER)||';'
    5 FROM av_abst_mp_ifrs
    6 WHERE stichtag='20081230'
    7 AND kontonummer='9851674900'
    8 /
    

    Not tested.

    Another option (without concat all the columns) to sqlplus, you can use "COLSEP. Like this...

    sql> SELECT 'DATE', SYSDATE
      2  FROM DUAL;
    
    'DAT SYSDATE
    ---- --------
    DATE 29/01/09
    
    1 row selected.
    
    sql> SELECT 'DATE'||SYSDATE
      2  FROM DUAL;
    
    'DATE'||SYSD
    ------------
    DATE29/01/09
    
    1 row selected.
    
    -- "OR"
    
    sql> SET COLSEP ''
    sql> SELECT 'DATE', SYSDATE
      2  FROM DUAL;
    
    'DATSYSDATE
    ------------
    DATE29/01/09
    
    1 row selected.
    

    Published by: dask99 on January 29, 2009 09:14
    Added new option.

  • Recently introduced an iPhone out of someone and the access code is still and I do not know Apple ID them and I can not get on the phone and do not have access to a computer so what do I do?

    Recently introduced an iPhone out of someone and the access code is still and I do not know Apple ID them and I can not get on the phone and do not have access to a computer so what do I do?

    You must contact the seller and ask him to remove this iPhone in the devices list. Otherwise, your iPhone will be a useless brick.

    Find my iPhone Activation Lock: a mechanism of extraction of the previous owner - Apple Support

  • Tecra A7: Is it ok to remove the battery and store it outside of the laptop?

    I took out the battery of Tecra A7 my wife so that it does not load and offload unnecessarily (laptop works exclusively on the sector).

    However, I read on the Internet that to take out the battery can sometimes be dangerous to its electronic components: namely, electronics no longer works correctly and the battery is considered to place in Notepad, as 'dead', even if this isn't really so.

    This can happen with my Toshiba battery, too?

    I did the same thing with my older Satellite P20. I put t see any problem here. But it is recommended to charge the battery and run the laptop on battery only from time to time. Charge the battery up and he sometimes empty. It's good for each rechargeable battery.

    I put t know where you found this info but believe me you can remove the battery and laptop can run on power only.

Maybe you are looking for