Regular expression does not execute runtime

Hello adobe collegue's,
I am currently stumbling on a strange issue regarding javascript embedded to compress a string:
// main function to compress any string, removing all non-word characters and making the string all lowercase
function compressString(input){
    var patt=new RegExp("\\W","g");
    patt.compile(patt);
    var output = input.toLowerCase().replace(patt,"")+"YESS";
    return output;
Somehow this code does execute perfectly while previewing in adobe designer 9.0.0.2 but runtime all javascript does execute except for the part mentioned above.
I know this part is executed because in the result i see the string "YESS" added to the response of this function.
Somehow the pattern is not compiled, or executed runtime...
I also tried more simple regular expressions but none of them actually worked.
For the templates the option client is set where to execute the javascript, although while testing the options to solve the issue is also tried settings both and server. None provided the solution.
Can someone provide any help...it's appreciated!
Thanks,
Marcel

Hi,
you can make your function more simple.
function compressString(input){
          return input.toLowerCase().replace(/\W/g,"") + "YESS";

Similar Messages

  • Regular expression does not work in IE

    Hi,
    I'm having a regular expression which should check the content of an inputText field: it should contain a number, a character and the size should be at least 6. It's working when I test it in FireFox but it always fails to succeed in IE:
              <af:inputText>
                <af:validateRegExp pattern="^(?=.*[a-zA-Z])(?=.*[0-9])[a-zA-Z0-9]{6,24}$"
                                   noMatchMessageDetail="Does not match."/>
              </af:inputText>How comes it does not work in IE (6.0)?
    JDeveloper 10.1.3.3
    Thanks in advance,
    Koen Verhulst

    hi Koen
    The web page you refer to ...
    http://www.fileformat.info/tool/regex.htm
    ... seems to be doing server side Java regular expressions (and as such will behave the same in both FF and IE).
    The af:validateRegExp component you want to use does client side evaluation of the regular expression, using scripting, hence the apparent difference between FF and IE.
    There is also this web page ...
    http://www.regular-expressions.info/javascriptexample.html
    ... that seems to behave similar to the markup and scripting resulting from the af:validateRegExp component.
    Besides the value "2abcdef" there seem to be others that are accepted by IE for the regular expression "^(?=.*[a-zA-Z])(?=.*[0-9])[a-zA-Z0-9]{6,24}$", values like these:
    "a2abcdef", "a2abcde", "abcdef2abcde", "2a3cdef", "2a34567"
    Although these values are not accepted by IE (but are accepted in FF):
    "2abcde", "23bcdef"
    success
    Jan

  • Match Regular Expression does not match what Match Pattern does

    I have read through a lot of posts about how Match Pattern does not match what Match Regular Expression will due to not processing some characters.
    However, I found a problem with the other way. A simple Reg-Ex that works in Match Pattern but not Match Regular Expression.
    What I have here is just an example. I want to use Match Regular Expression so I can specify some sub-matches.
    The reg-ex is for: one or more non-numeric characters, a space, one or more numeric characters. At the start of the string.
    How can I get this working in Match Regular Expression? I am working in LabVIEW 2010f2 32 bit. Here is the code snippet and the results:
    Rob
    Solved!
    Go to Solution.

    Robert Cole wrote:
    I think I prefer the ~ for negation since ^ is also used for beginning of the string. But we work with what we have.
    Let me offer you a tip and perhaps defend the honor of the regex a little bit.  One of my favorite features of regexes is the ability to specify character classes (and their negation).  One of the reasons I have to think about the ~ versus ^ is that I rarely use ^ in a regex alternative. 
    Some examples:
    [0-9] = \d (digit)
    [^0-9] = \D (not a digit)
    The equivalent regex for your case is: \D+ \d+

  • SQL-Tokenizer based on regular-expressions does not work

    I'm on 10gR2
    Following SQL-Tokenizer converts string :str to rows using :delim as the delimiter-char (:str and :delim are parameters):
    select level, regexp_replace(regexp_substr( :in_str || :in_delimiter, '(.*?)' || :in_delimiter, 1, level ), :in_delimiter, '') as token
    from dual
    connect by regexp_instr( :in_str || :in_delimiter, '(.*?)' || :in_delimiter, 1, level ) > 0
    order by level asc ;
    When using the pipe-symbol "|" as the delimiter, it doesn't work; the rows are processed, but the tokens are null. Using an other char as delimiter (e.g. ";") works fine.
    :str = "123;456;A1;67X;0;-8" & :delim = ";" => works fine
    :str = "123|456|A1|67X|0|-8" & :delim = "|" => does not work
    I think the bug is in the regexp-parameter for the pattern, isn't it?
    Why doesn't work the pipe-symbol as delimiter?
    Can anybody give me a hint for using the correct regexp-pattern?
    thx
    Nuerni

    select level, rtrim(regexp_substr( :in_str || :in_delimiter, '(.*?)' || :in_delimiter, 1, level ),:in_delimiter ) as token
    from dual
    connect by regexp_instr( :in_str || :in_delimiter, '(.*?)' || :in_delimiter, 1, level ) > 0
    order by level asc ;use a rtrim instead of regexp_replace then it works...
    Ravi Kumar

  • My new airport express does not connect my printer to my computer?  My old airport did! then I updated to OS 10.9.2.  How do I get it connected?

    My new airport express does not connect my printer to my computer.  The old airport did.  I recently updated to OS 10.9.2.  I have since bought a new
    HP 6700 all in one wireless printer,  got the latest Comcast router.  None of which connect to my computer wirelessly.  Which do I throw away the printer, router, or Mac?  Help

    Contact HP for support.
    Explain that you are using a Mac, anticipate the inevitable groan, and wait patiently for their resident Mac expert to return from vacation.
    Until then download and install its driver here: http://h10025.www1.hp.com/ewfrf/wc/softwareCategory?product=5058338&cc=us&dlc=en &lc=en
    Otherwise return the printer and purchase one from a company that visibly supports OS X. HP isn't on that list.

  • Xslt error: the expression does not evaluate to a node-set

    hi guys - i'm really down because i cannot find / understand my xsl error and i have to finish my work very very soon
    the error message (by using xalan to create from the xml file my html output) is the following:
    xslt error: the expression does not evaluate to a node-set
    and the code fragement is:
    <xsl:template name="getNext">
    <xsl:param name="currentKnoten" />
    <xsl:for-each select="$currentKnoten"> //error is in this line
    </xsl:for-each>
    </xsl:template>please... help me....

    ok thanks!!! this saved me some time ;-)
    now i go back to the origin problem... my main idea is the following xsl code... may u can see here the problem with the node site.. but i think u need the xml file or?
    however this is my relevant xsl code:
    <xsl:template match="DATA">
              <xsl:element name="process">
                   <xsl:attribute name="name">
                        <xsl:value-of select="@name" />
                   </xsl:attribute>
                   <xsl:apply-templates select="INSTANCE"/>
              </xsl:element>
         </xsl:template>
    <xsl:template match="INSTANCE[@class='Data']">
              <xsl:element name="node">
                   <xsl:attribute name="name">
                        <xsl:value-of select="@name" />
                   </xsl:attribute>
                   <xsl:attribute name="class">
                        <xsl:value-of select="@class" />
                   </xsl:attribute>
                   <xsl:call-template name="copyAttributes" />
                   <xsl:variable name="nextNodes">
                        <xsl:value-of select="key('keyGetData', key('keyFrom', @name)/../TO/@instance)" />
                   </xsl:variable>
                   <xsl:call-template name="getNext">
                        <xsl:with-param name="currentNode" select="$nextNodes" />
                   </xsl:call-template>
              </xsl:element>
    </xsl:template>     
    <xsl:template name="getNext">
              <xsl:param name="currentNode"/>
              <xsl:for-each select="$currentNode">
                   <xsl:element name="node">
                        <xsl:attribute name="name"><xsl:value-of select="@name"/></xsl:attribute>
                        <xsl:attribute name="class"><xsl:value-of select="@class"/></xsl:attribute>
                        <xsl:variable name="nextNodes">
                             <xsl:value-of select="key('keyGetData', key('keyFrom', @name)/../TO/@instance)"/>
                        </xsl:variable>
                        <xsl:call-template name="copyAttributes"/>
                        <xsl:call-template name="getNext">
                             <xsl:with-param name="currentNode" select="$nextNodes"/>
                        </xsl:call-template>
                   </xsl:element>
              </xsl:for-each>
         </xsl:template>
         <xsl:template name="copyAttributes">
              <xsl:for-each select="descendant::*">
                   <xsl:copy>
                        <xsl:copy-of select="@*|node()"/>
                   </xsl:copy>
              </xsl:for-each>
         </xsl:template>
         <xsl:template match="@*|node()">
              <xsl:apply-templates/>
         </xsl:template>

  • When I touch my iPad screen to execute an app, the screen goes dark then the app icon reappears. The app does not execute.

    When I touch my iPad screen to execute an app, then the screen goes dark then the app icon reappears. The app does not execute. Any thoughts?

    Try a Reset...
    Press and hold the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears. Release the Buttons.
    Basic troubleshooting
    From Here
    http://www.apple.com/support/ipad/basics/

  • Oracle ADF refresh as deferred does not execute query on page load

    In the oracle ADF page I have two panel boxes. (Oracle ADF 11.1.1.4)
    a) Personal information panel box with PanelFormLayout (PersonalInfoViewObj) - ReadOnly View Object
    b) Address information panel box with Table (AddressInfoViewObj) - Read Only View Object
    For the iterators in a) and b) I have kept refresh condition as deferred and cacheResult=false. Also in b) for af:table, I have kept contentDelivery="immediate"
    When page loads it fires SQL query for a) and populate the data in Personal information panel box. However for b) it does not execute the SQL query and the data is not getting populated ( in AddressInformation panel with the tables. Please note data is there in the DATABASE......)
    Becasue with the refresh as deferred it was not executing the sql query for Panel b) (panel with Table and table iterator). I have tried refresh as always and refresh ifNeeded/renderModel/prepareModel however in that case it is executing the SQL query two times (twice).
    Please let me know the best way to fix this issue.

    Hi,
    I think you need a method in an application module to init your data.
    In your AM : create a method like :
    public void init(){
    getViewObject().executeQuery();
    }In your adfc-config.xml create a methodCall from this method and a "control flow case" from the methodCall to your page.
    and keep refresh as "deferred " in your pageDef.
    Clément

  • Global succession updates are limited to 500 relationships. If more than 500 exist PLM presents a warning message and does not execute the update

    Global succession updates are limited to 500 relationships. If more than 500 exist PLM presents a warning message and does not execute the update.
    How/Where to increase the relationship count?
    The message which I can see :
    Warning:
    This specification has exceeded the number of parent relationships allowed by Where Used. The Where Used tool only supports up to 500 parent relationships.
    Thanks

    This really brings up a larger topic around change management.
    The questions you should start with is
    1. What kind of change is happening to the raw material? 
    2. Will this change affect anything upstream inside or outside of PLM4P? (Will this change affect nutrition, compliance, the ingredient statement, the label etc?)
    3. Who needs to approve this change?
    If they are non-material changes (changes that don't affect theoretical calculations, the ingredient statement, labeling, upstream systems that need to be notified etc) then you should be using get latest revision instead of global succession.   Get Latest Revision will automatically switch out the material with the latest approved version.  This logic is also configurable in case you need to add additional guard conditions.   We can also provide guidance around locking the get latest revision lock once a specification has reached the retired/obsolete state so changes won't occur for specifications in those statuses.
    If the changes to the raw material are material changes (changes that affect calculations, labeling etc) then the change should be reflected with a copy of the specification.  Dependent specifications then need to be re-issued so calculations can be performed and the appropriate workflow reviews can occur.   Smart Issue allows for filtering based on status and should let you re-issue in smaller blocks. 
    Let me know more about your change management strategy, how often large material changes happen and maybe example causes for those mass changes.  We can also schedule a change management training session for everyone where we can share our vision and tools available for change management.  This topic is quite large and generally requires a lot of business process discussion beyond just the tools available. 
    Thanks
    Kelly

  • User exit code does not execute

    I'm having a problem with User exit code that does not execute yet seems to be set up correctly.
    The User exit is implemented as FM "EXIT_SAPLIPW1_001" in function group XQSM.
    I've tried everything I know of with the CMOD and SMOD transactions, and I suspect some sort of transport error.
    The only clue I can find in comparing the development system (which works) with the test system (which does not work) is that running "Extended Check" in SE80 on function group XQSM fails with the following error:
    "The namespace of program SAPLXQSM has the setting "C" and cannot be tested."
    Has anyone any idea what could have happened?

    Let us try to retrace the steps.
    1. You created a Z project in CMOD and assigned the enhancement IQSM0001 and the component EXIT_SAPLIPW1_001 and activated the same. This is there in the transport.
    2. You double clicked on the include in the user exit and created it. You activated the code and included it in the same transport.
    If you did the above steps, then your user exit should be active in your test system.
    Can you please go to SE10, and list out the objects in your transport? You should see entries in there like below(not necessarily a complete list)
    R3TR CMOD <your project name>
    R3TR PROG ZXQSMU01
    See if you created any of the objects as local objects.
    Srinivas

  • Getting descriptor version does not match runtime version error

    Thanks,
    I am Using Adope Air SDK2.0 and Runtime Air 1.0.7,
    i have created one HelloWorld application using Adope sample
    code.
    When i am trying to run this using commands :
    i have used : adl HelloWorld.html
    i am getting this error:
    invalid application descriptor: descriptor version does not
    match runtime version
    Plz help me out.. :-)

    The issue I had in Flashbuilder4 has been solved.
    The easiest but possibly not the neatest was too copy the AIR 2 Beta SBK folders and files, then paste the over the flex4.0 sdk file structure. Achieves the same thing and I assume that you have copies of the SDK else where, if you need to roll back.
    The other thing is to make sure the -app.xml that flex creates has the correct 2.0beta description.
    Cheers
    Elliot

  • Hi, The Airport Express does not work with iOS 7.0.4, I appreciate your help to resolve this event. Thank you,

    Hi, The Airport Express does not work with iOS 7.0.4, I appreciate your help to resolve this event. Thank you,

    Please locate the model number of the AirPort Express and post back that information.
    The model number is located on the side of the AirPort Express. It begins with an "A" followed by four numbers.
    We are not sure what you mean by "does not work".  Does this mean that the AirPort Express worked at one time and has just recently stopped working?
    Have you installed a newer operating system on your iOS device recently?
    Or, is this a new AirPort Express that you are trying to configure for the first time?
    If yes, what service will the AirPort Express perform on your network?
    Please remember that we cannot see your network, so we only know as much about your problem as you can tell us.

  • Actions does not executed on quotation saved.

    Hi,
    Actions does not executed on quotation save.
    Action profiles has been created as per my production system.
    In production system it is executing properly. but in development system it does not get triggered.
    Pls suggest.
    Points will be rewarded.
    Thanks

    Hi Vinayak
    U can check in 'Define Conditions' for the actions and see whether the actions for the Action profile have been scheduled or not.
    On the left hand side u get the action profiles. U can right click on that and schedule the actions.
    Plz reward points if it helps.
    Thanks and regards
    Debolina

  • Tcode opens selection screen, but does not executes the program

    Hi!
    tcode opens selection screen of a custom program, but it seems that it does not executes the program itself.
    Sounds strange, but how to explain this if I can run a program manually with no problem and it displays result screen, but when I try to run the program with tcode - it opens selection screen but program quits before displaying result screen. I was putting a breakpoint at the begining of the program - it does not triggers debuger when running a tcode (it triggers debugger if to run program manually).... any ideas?
    Help will be appreciated,
    Mindaugas

    Are you using this???
          SET PARAMETER ID '80B' FIELD T_TABLE-OPBEL.
          CALL TRANSACTION 'FPE3' AND SKIP FIRST SCREEN.
    That way it should work....
    Greetings,
    Blag.

  • My calendar is stuck. i press 'done' and it stays as is.  I noticed this on my contacts also. it sometimes does not execute.

    my calendar is stuck. i press 'done' and it stays as is.  I noticed this on my contacts also. it sometimes does not execute.

    http://support.apple.com/kb/TS3281
    Apple does not respond here this is a user to user forum There are no Apple staff here
    Millions have updated without issue

Maybe you are looking for